Submission #1286151

#TimeUsernameProblemLanguageResultExecution timeMemory
1286151lyra_g13Square or Rectangle? (NOI19_squarerect)C++20
Compilation error
0 ms0 KiB
#include "squarerect.h"
#include <bits/stdc++.h>
using ll = long long;
    bool am_i_square(int N, int Q){
     
       for(int i = 1 ; i <= 100, c >=0 ; i++){
           for(int j = 1 ; j <= 100 , c>=0 ; j++){
               c--;
               return inside_shape(i , j);
           }
       }

 }

Compilation message (stderr)

squarerect.cpp: In function 'bool am_i_square(int, int)':
squarerect.cpp:6:34: error: 'c' was not declared in this scope
    6 |        for(int i = 1 ; i <= 100, c >=0 ; i++){
      |                                  ^
squarerect.cpp:6:16: warning: control reaches end of non-void function [-Wreturn-type]
    6 |        for(int i = 1 ; i <= 100, c >=0 ; i++){
      |                ^