제출 #1317111

#제출 시각아이디문제언어결과실행 시간메모리
1317111belmostefaArranging Shoes (IOI19_shoes)C++20
컴파일 에러
0 ms0 KiB
#include<iostream> using namespace std; int64_t count_swaps(int[] s){ if(s[0]<0){ return 0; }else{ return 1; } }

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

shoes.cpp:3:27: error: expected ',' or '...' before 's'
    3 | int64_t count_swaps(int[] s){
      |                           ^
shoes.cpp: In function 'int64_t count_swaps(int*)':
shoes.cpp:4:6: error: 's' was not declared in this scope
    4 |   if(s[0]<0){
      |      ^
shoes.cpp:9:1: warning: control reaches end of non-void function [-Wreturn-type]
    9 | }
      | ^