Language: C

int main(void){
  int input;
  string output = "No";
  
  cin >> input;
  
  if(judgeSeven_100() == true){
    output = "YES";
  }
  else if(judgeSeven_10() == true){
  	output = "YES";
  }
  else if(judgeSeven_1() == true){
    output = "YES";
  }
  
  cout << output;
}  

bool judgeSeven_100(int input){
	int hundredsPlace = input / 100;
  	bool isSeven = false;
  
  if(hundredsPlace == 7){
  	isSeven = true;
  }
  	
  return isSeven;
}

bool judgeSeven_10(int input){
	int tensPlace = (input % 100) / 10;
  bool isSeven = false;
  
  if(tensPlace == 7){
    isSeven = true;
  }
  
	return isSeven;
}

bool judgeSeven_1(int input){
	int onesPlace = (input % 10);
  bool isSeven = false;
  
  if(onesPlace == 7){
  	isSeven = true;
  }

  return isSeven;
}

Compiler output:
main.c: In function 'main':
main.c:3:3: error: unknown type name 'string'
    3 |   string output = "No";
      |   ^~~~~~
main.c:3:19: error: initialization of 'int' from 'char *' makes integer from pointer without a cast [-Wint-conversion]
    3 |   string output = "No";
      |                   ^~~~
main.c:5:3: error: 'cin' undeclared (first use in this function)
    5 |   cin >> input;
      |   ^~~
main.c:5:3: note: each undeclared identifier is reported only once for each function it appears in
main.c:7:6: error: implicit declaration of function 'judgeSeven_100' [-Wimplicit-function-declaration]
    7 |   if(judgeSeven_100() == true){
      |      ^~~~~~~~~~~~~~
main.c:7:26: error: 'true' undeclared (first use in this function)
    7 |   if(judgeSeven_100() == true){
      |                          ^~~~
main.c:1:1: note: 'true' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
  +++ |+#include <stdbool.h>
    1 | int main(void){
main.c:8:12: error: assignment to 'int' from 'char *' makes integer from pointer without a cast [-Wint-conversion]
    8 |     output = "YES";
      |            ^
main.c:10:11: error: implicit declaration of function 'judgeSeven_10' [-Wimplicit-function-declaration]
   10 |   else if(judgeSeven_10() == true){
      |           ^~~~~~~~~~~~~
main.c:11:16: error: assignment to 'int' from 'char *' makes integer from pointer without a cast [-Wint-conversion]
   11 |         output = "YES";
      |                ^
main.c:13:11: error: implicit declaration of function 'judgeSeven_1' [-Wimplicit-function-declaration]
   13 |   else if(judgeSeven_1() == true){
      |           ^~~~~~~~~~~~
main.c:14:12: error: assignment to 'int' from 'char *' makes integer from pointer without a cast [-Wint-conversion]
   14 |     output = "YES";
      |            ^
main.c:17:3: error: 'cout' undeclared (first use in this function)
   17 |   cout << output;
      |   ^~~~
main.c: At top level:
main.c:20:1: error: unknown type name 'bool'
   20 | bool judgeSeven_100(int input){
      | ^~~~
main.c:20:1: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c: In function 'judgeSeven_100':
main.c:22:9: error: unknown type name 'bool'
   22 |         bool isSeven = false;
      |         ^~~~
main.c:22:9: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c:22:24: error: 'false' undeclared (first use in this function)
   22 |         bool isSeven = false;
      |                        ^~~~~
main.c:22:24: note: 'false' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c:25:19: error: 'true' undeclared (first use in this function)
   25 |         isSeven = true;
      |                   ^~~~
main.c:25:19: note: 'true' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c: At top level:
main.c:31:1: error: unknown type name 'bool'
   31 | bool judgeSeven_10(int input){
      | ^~~~
main.c:31:1: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c: In function 'judgeSeven_10':
main.c:33:3: error: unknown type name 'bool'
   33 |   bool isSeven = false;
      |   ^~~~
main.c:33:3: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c:33:18: error: 'false' undeclared (first use in this function)
   33 |   bool isSeven = false;
      |                  ^~~~~
main.c:33:18: note: 'false' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c:36:15: error: 'true' undeclared (first use in this function)
   36 |     isSeven = true;
      |               ^~~~
main.c:36:15: note: 'true' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c: At top level:
main.c:42:1: error: unknown type name 'bool'
   42 | bool judgeSeven_1(int input){
      | ^~~~
main.c:42:1: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c: In function 'judgeSeven_1':
main.c:44:3: error: unknown type name 'bool'
   44 |   bool isSeven = false;
      |   ^~~~
main.c:44:3: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c:44:18: error: 'false' undeclared (first use in this function)
   44 |   bool isSeven = false;
      |                  ^~~~~
main.c:44:18: note: 'false' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c:47:19: error: 'true' undeclared (first use in this function)
   47 |         isSeven = true;
      |                   ^~~~
main.c:47:19: note: 'true' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'