제출 #526680

#제출 시각아이디문제언어결과실행 시간메모리
526680Hydroxic_AcidAutići (COCI22_autici)C++14
0 / 50
1 ms204 KiB
#include <iostream> #include <queue> using namespace std; #define ll long long int N; ll length[100005]; int main(){ freopen("test.txt", "r", stdin); cin >> N; ll minn = 1000000000; for(int i = 0; i < N; i++){ cin >> length[i]; minn = min(minn, length[i]); } ll summ = minn * N; for(int i = 0; i < N; i++){ summ += length[i]; } summ -= minn; summ -= minn; cout << summ; }

컴파일 시 표준 에러 (stderr) 메시지

Main.cpp: In function 'int main()':
Main.cpp:10:12: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
   10 |     freopen("test.txt", "r", stdin);
      |     ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...