일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 | 31 |
Tags
- 조건문
- 배열
- sql injection
- burp suite
- object
- blind sql injection
- github
- 객체
- 파이썬
- 사칙연산
- 포인터
- 백준 알고리즘
- 함수
- window
- 김성엽 대표님
- htmlspecialchars
- property
- element 조회
- IF문
- 백준 파이썬
- 자바스크립트
- lord of sql injection
- document
- jQuery
- xss game
- xss game 풀이
- 메소드
- suninatas 풀이
- python
- Pwndbg
Archives
- Today
- Total
power-girl0-0
[ C++ ] 반 평균 구하기 본문
728x90
#include <iostream> using namespace std; int main(){ string name; const int student = 5; int score[student], sum; cout << "지도 교수명 : "; getline(cin,name); cout << endl; for(int i=0; i<student; i++){ cout<<i+1<<"번 학생 점수를 입력해주세요."<<endl; cin>>score[i]; sum += score[i]; } cout << endl<<"지도교수명 : "<<name <<endl; cout << "합 : "<<sum<<", 평균 : "<<(float)sum/student<<endl; }

728x90
'언어 > C++' 카테고리의 다른 글
[ C++ ] 클래스 & 객체 (0) | 2021.03.23 |
---|---|
[ C++ ] 해밍코드 거리 구하기 (0) | 2021.03.23 |
[ C++ ] 랜덤한 수 합 맞추기 (0) | 2021.03.23 |
[ C++ ] 문자를 입력받아 모음과 자음 수 구하기 (0) | 2021.03.23 |
[ C++ ] 랜덤 수 & 최대값 & 정렬 (0) | 2021.03.16 |
Comments