criyle/codenet-compile-errors huggingface dataset:
Language: C

#include<stdio.h>
int main()
{
    int i,ln;
    char s[10000];
    gets(s);
    
    s[ln]<1200;
    for(ln=0;s[ln]!='\0';ln++);
   for(i=0;i<ln;i++)
    {
     if(s[i]>='A' && s[i]<='Z')
     {
        s[i]=s[i]+32;
     }
        else if(s[i]>='a' && s[i]<='z')
        {
            s[i]=s[i]-32;
        }

    }
printf("%s\n",s);



    return 0;
}



Compiler output:
main.c: In function 'main':
main.c:6:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 |     gets(s);
      |     ^~~~
      |     fgets
Language: C

#include<stdio.h>
int main()
{
    int i,ln;
    char s[10000];
    gets(s);

    for(ln=0;s[ln]!='\0';ln++);
   for(i=0;i<ln;i++)
    {
     if(s[i]>='A' && s[i]<='Z')
     {
        s[i]=s[i]+32;
     }
        else if(s[i]>='a' && s[i]<='z')
        {
            s[i]=s[i]-32;
        }

    }
printf("%s\n",s);



    return 0;
}



Compiler output:
main.c: In function 'main':
main.c:6:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 |     gets(s);
      |     ^~~~
      |     fgets
Language: C

#include<stdio.h>
int main()
{
    int i=0;
    char str[1199],str2[1199];
    gets(str);
    while(str[i]!='\0')
    {
        if(str[i]>=97&&str[i]<=122)
        {
            str2[i] = str[i]-32;
        }
        else if(str[i]>=65&&str[i]<=90)
        {
            str2[i] = str[i]+32;
        }
        else
        {
            str2[i] = str[i];
        }
        i++;
    }
    str2[i] = '\0';
    puts(str2);
    return 0;
}



Compiler output:
main.c: In function 'main':
main.c:6:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 |     gets(str);
      |     ^~~~
      |     fgets
Language: C

#include<stdio.h>
#include<string.h>
int main()
{
          char ch[1000],CH[1000],i,j,k,n;
          gets(ch);
          n=strlen(ch);
          for(i=0;i<n;i++)
          {
                    if(ch[i]>=97&&ch[i]<=122)
                    {
                              CH[i]=ch[i]-32;
                    }
                    else if(ch[i]>=65&&ch[i]<=90)
                            {
                                CH[i]=ch[i]+32;
                            }
          }
          puts(CH);
          return 0;

}



Compiler output:
main.c: In function 'main':
main.c:6:11: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 |           gets(ch);
      |           ^~~~
      |           fgets
Language: C

#include <stdio.h>
#include <ctype.h>
#include <stdlib.h>

int main()
{
    char buf[1250];
    char *p, c;

    gets(buf);
    p = buf;
    while (*p) {
        c = *p++;
        if (isupper(c)) c = tolower(c);
        else if (islower(c)) c = toupper(c);
        putchar(c);
    }
    putchar('\n');
    return 0;
}



Compiler output:
main.c: In function 'main':
main.c:10:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   10 |     gets(buf);
      |     ^~~~
      |     fgets
Language: C

#include<string.h>
int main()
{
    char s[1200];
    int t,i;
    gets(s);
    t=strlen(s);
    for(i=0;i<t;i++)
    {
        if(s[i]>='A' && s[i]<='Z')
        {
            s[i]=s[i]+32;
        }
        else if(s[i]>='a' && s[i]<='z')
        {
            s[i]=s[i]-32;
        }
        else
        {
            s[i]=s[i];
        }
    }
    puts(s);
}



Compiler output:
main.c: In function 'main':
main.c:6:5: error: implicit declaration of function 'gets' [-Wimplicit-function-declaration]
    6 |     gets(s);
      |     ^~~~
main.c:23:5: error: implicit declaration of function 'puts' [-Wimplicit-function-declaration]
   23 |     puts(s);
      |     ^~~~
main.c:2:1: note: include '<stdio.h>' or provide a declaration of 'puts'
    1 | #include<string.h>
  +++ |+#include <stdio.h>
    2 | int main()
Language: C

#include<string.h>
int main()
{
    char s[1200];
    int t,i;
    gets(s);
    t=strlen(s);
    for(i=0;i<t;i++)
    {
        if(s[i]>='A' && s[i]<='Z')
        {
            s[i]=s[i]+32;
        }
        else if(s[i]>='a' && s[i]<='z')
        {
            s[i]=s[i]-32;
        }
        else
        {
            s[i]=s[i];
        }
    }
    puts(s);
}


Compiler output:
main.c: In function 'main':
main.c:6:5: error: implicit declaration of function 'gets' [-Wimplicit-function-declaration]
    6 |     gets(s);
      |     ^~~~
main.c:23:5: error: implicit declaration of function 'puts' [-Wimplicit-function-declaration]
   23 |     puts(s);
      |     ^~~~
main.c:2:1: note: include '<stdio.h>' or provide a declaration of 'puts'
    1 | #include<string.h>
  +++ |+#include <stdio.h>
    2 | int main()
Language: C

#include<stdio.h>
int main()
{
    int n=0,i;
    char a[1200],b[1200];
    gets(a);
    while(a[n]!='\0')
    n++;
    for(i=0;i<n;i++)
    {
        if(a[i]>'A'&&a[i]<='Z'){
        b[i]=a[i]+32;}
         else if(a[i]>='a'&&a[i]<='z')
        {b[i]=a[i]-32;}
         else
          {

           b[i]=a[i];}

    }
    printf("%s\n",b);
    getch();
    return 0;
}



Compiler output:
main.c: In function 'main':
main.c:6:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 |     gets(a);
      |     ^~~~
      |     fgets
main.c:22:5: error: implicit declaration of function 'getch'; did you mean 'getc'? [-Wimplicit-function-declaration]
   22 |     getch();
      |     ^~~~~
      |     getc
Language: C

#include <stdio.h>
#include <ctype.h>

int main(void)
{

    char moji;
    
    while(1)
    {
        scanf("%c",&moji);
        if(moji=='.'){printf("%c",moji); break;}
        else
        {
            if(moji>='a' && moji<='z')
            {
                printf("%c",toupper(moji));
            }
            else if(moji>='A' && moji<='Z')
            {
                printf("%c",tolower(moji));
            }
            else printf("%c",moji);
        }
    }
    
    return 0;
}

}



Compiler output:
main.c:30:1: error: expected identifier or '(' before '}' token
   30 | }
      | ^
Language: C

#include <stdio.h>
#include <string.h>

int main(void) {
    char str[1200];
    int i;

    while((str=getchar())!=EOF );
    //printf("%s\n", str);
    for (i=0; i<=sizeof(str); i++) {
        if (str[i]<=122 && str[i]>=97) {
	    str[i]-=32;
	} else if (str[i]<=90 && str[i]>=65) {
	    str[i]+=32;
	}
    }
    printf("%s\n", str);
    
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:8:15: error: assignment to expression with array type
    8 |     while((str=getchar())!=EOF );
      |               ^
Language: C

#include <stdio.h>
#include <math.h>
#include <string.h>
#include <stdlib.h>
#include <ctype.h>
char t[100000];
int main(int argc, const char * argv[]) {
        int i;
        int n;
        gets(t);
        n=strlen(t);
        for(i=0;i<n;i++){
            if(islower(t[i])){
             printf("%c",toupper(t[i]));
            }
            else if(isupper(t[i])){
                printf("%c",tolower(t[i]));

            }else{
             printf("%c",t[i]);
            }
        }
    puts("");
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:10:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   10 |         gets(t);
      |         ^~~~
      |         fgets
Language: C

#include <stdio.h>
#include <string.h>
char t[100000];
int main(int argc, const char * argv[]) {
        int i;
        int n;
        gets(t);
        n=strlen(t);
        for(i=0;i<n;i++){
            if(islower(t[i])) printf("%c",toupper(t[i]));
        else if(isupper(t[i])) printf("%c",tolower(t[i]));
        else printf("%c",t[i]);
    }
    puts("");
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:7:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    7 |         gets(t);
      |         ^~~~
      |         fgets
main.c:10:16: error: implicit declaration of function 'islower' [-Wimplicit-function-declaration]
   10 |             if(islower(t[i])) printf("%c",toupper(t[i]));
      |                ^~~~~~~
main.c:3:1: note: include '<ctype.h>' or provide a declaration of 'islower'
    2 | #include <string.h>
  +++ |+#include <ctype.h>
    3 | char t[100000];
main.c:10:43: error: implicit declaration of function 'toupper' [-Wimplicit-function-declaration]
   10 |             if(islower(t[i])) printf("%c",toupper(t[i]));
      |                                           ^~~~~~~
main.c:10:43: note: include '<ctype.h>' or provide a declaration of 'toupper'
main.c:11:17: error: implicit declaration of function 'isupper' [-Wimplicit-function-declaration]
   11 |         else if(isupper(t[i])) printf("%c",tolower(t[i]));
      |                 ^~~~~~~
main.c:11:17: note: include '<ctype.h>' or provide a declaration of 'isupper'
main.c:11:44: error: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
   11 |         else if(isupper(t[i])) printf("%c",tolower(t[i]));
      |                                            ^~~~~~~
main.c:11:44: note: include '<ctype.h>' or provide a declaration of 'tolower'
Language: C

#include<stdio.h>
#include<stdlib.h>
#define L 1201

int main(void){

  int i;
  i=0;
  char str[L];

  gets(str);

  while(i < L){

    if(str[i] >= 65 && str[i] <= 90){
      str[i] += 32;
    }else if(str[i] >= 97 && str[i] <= 122){
      str[i] -= 32;
    }
    i++;
  }

  printf("%s\n", str);


  return 0;
}



Compiler output:
main.c: In function 'main':
main.c:11:3: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   11 |   gets(str);
      |   ^~~~
      |   fgets
Language: C

#include <stdio.h>
#include <ctypw.h>

int main(void) {
	char c[1200];
	while(1){
		if(c == "\n") break;
		else if((islower(c)) == 0)
			c = toupper(c);
		else if((isupper(c)) != 0)
			c = tolower(c);
		putchar("%c", c);
	}
	putchar('\n');
	return 0;
}



Compiler output:
main.c:2:10: fatal error: ctypw.h: No such file or directory
    2 | #include <ctypw.h>
      |          ^~~~~~~~~
compilation terminated.
Language: C

#include <stdio.h>
#include <ctype.h>

int main(void) {
	char c[1200];
	while(1){
		if(c == '\n') break;
		else if((islower(c)) == 0)
			c = toupper(c);
		else if((isupper(c)) != 0)
			c = tolower(c);
		putchar("%c", c);
	}
	putchar('\n');
	return 0;
}



Compiler output:
main.c: In function 'main':
main.c:7:22: warning: comparison between pointer and integer
    7 |                 if(c == '\n') break;
      |                      ^~
main.c:9:37: error: passing argument 1 of 'toupper' makes integer from pointer without a cast [-Wint-conversion]
    9 |                         c = toupper(c);
      |                                     ^
      |                                     |
      |                                     char *
In file included from main.c:2:
/usr/include/ctype.h:125:25: note: expected 'int' but argument is of type 'char *'
  125 | extern int toupper (int __c) __THROW;
      |                     ~~~~^~~
main.c:9:27: error: assignment to expression with array type
    9 |                         c = toupper(c);
      |                           ^
main.c:11:37: error: passing argument 1 of 'tolower' makes integer from pointer without a cast [-Wint-conversion]
   11 |                         c = tolower(c);
      |                                     ^
      |                                     |
      |                                     char *
/usr/include/ctype.h:122:25: note: expected 'int' but argument is of type 'char *'
  122 | extern int tolower (int __c) __THROW;
      |                     ~~~~^~~
main.c:11:27: error: assignment to expression with array type
   11 |                         c = tolower(c);
      |                           ^
main.c:12:25: error: passing argument 1 of 'putchar' makes integer from pointer without a cast [-Wint-conversion]
   12 |                 putchar("%c", c);
      |                         ^~~~
      |                         |
      |                         char *
In file included from main.c:1:
/usr/include/stdio.h:618:25: note: expected 'int' but argument is of type 'char *'
  618 | extern int putchar (int __c);
      |                     ~~~~^~~
main.c:12:17: error: too many arguments to function 'putchar'
   12 |                 putchar("%c", c);
      |                 ^~~~~~~
/usr/include/stdio.h:618:12: note: declared here
  618 | extern int putchar (int __c);
      |            ^~~~~~~
Language: C

#include <stdio.h>
#include <ctype.h>
int main(void){
    char c[1200];
    while(1){
        scanf("%c", &c);
        if(isupper(c) != 0)
            c = tolower(c);
        else
            c = toupper(c);
        printf("%c", c);
        if(c == '\n')break;
    }
    putchar('\n');
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:8:25: error: passing argument 1 of 'tolower' makes integer from pointer without a cast [-Wint-conversion]
    8 |             c = tolower(c);
      |                         ^
      |                         |
      |                         char *
In file included from main.c:2:
/usr/include/ctype.h:122:25: note: expected 'int' but argument is of type 'char *'
  122 | extern int tolower (int __c) __THROW;
      |                     ~~~~^~~
main.c:8:15: error: assignment to expression with array type
    8 |             c = tolower(c);
      |               ^
main.c:10:25: error: passing argument 1 of 'toupper' makes integer from pointer without a cast [-Wint-conversion]
   10 |             c = toupper(c);
      |                         ^
      |                         |
      |                         char *
/usr/include/ctype.h:125:25: note: expected 'int' but argument is of type 'char *'
  125 | extern int toupper (int __c) __THROW;
      |                     ~~~~^~~
main.c:10:15: error: assignment to expression with array type
   10 |             c = toupper(c);
      |               ^
main.c:12:14: warning: comparison between pointer and integer
   12 |         if(c == '\n')break;
      |              ^~
Language: C

#include <stdio.h>
int main(){
    int n;
    int i;
    char t[100000];
    gets(t);
    n=strlen(t);
    for(i=0;i<n;i++){
        if(islower(t[i]))
            printf("%c",toupper(t[i]));
        else if(isupper(t[i]))
            printf("%c",tolower(t[i]));
        else printf("%c",t[i]);
    }
    
}



Compiler output:
main.c: In function 'main':
main.c:6:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 |     gets(t);
      |     ^~~~
      |     fgets
main.c:7:7: error: implicit declaration of function 'strlen' [-Wimplicit-function-declaration]
    7 |     n=strlen(t);
      |       ^~~~~~
main.c:2:1: note: include '<string.h>' or provide a declaration of 'strlen'
    1 | #include <stdio.h>
  +++ |+#include <string.h>
    2 | int main(){
main.c:7:7: warning: incompatible implicit declaration of built-in function 'strlen' [-Wbuiltin-declaration-mismatch]
    7 |     n=strlen(t);
      |       ^~~~~~
main.c:7:7: note: include '<string.h>' or provide a declaration of 'strlen'
main.c:9:12: error: implicit declaration of function 'islower' [-Wimplicit-function-declaration]
    9 |         if(islower(t[i]))
      |            ^~~~~~~
main.c:2:1: note: include '<ctype.h>' or provide a declaration of 'islower'
    1 | #include <stdio.h>
  +++ |+#include <ctype.h>
    2 | int main(){
main.c:10:25: error: implicit declaration of function 'toupper' [-Wimplicit-function-declaration]
   10 |             printf("%c",toupper(t[i]));
      |                         ^~~~~~~
main.c:10:25: note: include '<ctype.h>' or provide a declaration of 'toupper'
main.c:11:17: error: implicit declaration of function 'isupper' [-Wimplicit-function-declaration]
   11 |         else if(isupper(t[i]))
      |                 ^~~~~~~
main.c:11:17: note: include '<ctype.h>' or provide a declaration of 'isupper'
main.c:12:25: error: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
   12 |             printf("%c",tolower(t[i]));
      |                         ^~~~~~~
main.c:12:25: note: include '<ctype.h>' or provide a declaration of 'tolower'
Language: C

#include <stdio.h>
#include <string.h>
   char t[100000];
int main(){
    int n;
    int i;
 
    gets(t);
    n=strlen(t);
    for(i=0;i<n;i++){
        if(islower(t[i]))
            printf("%c",toupper(t[i]));
        else if(isupper(t[i]))
            printf("%c",tolower(t[i]));
        else printf("%c",t[i]);
    }
    puts("");
    return 0;
}



Compiler output:
main.c: In function 'main':
main.c:8:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    8 |     gets(t);
      |     ^~~~
      |     fgets
main.c:11:12: error: implicit declaration of function 'islower' [-Wimplicit-function-declaration]
   11 |         if(islower(t[i]))
      |            ^~~~~~~
main.c:3:1: note: include '<ctype.h>' or provide a declaration of 'islower'
    2 | #include <string.h>
  +++ |+#include <ctype.h>
    3 |    char t[100000];
main.c:12:25: error: implicit declaration of function 'toupper' [-Wimplicit-function-declaration]
   12 |             printf("%c",toupper(t[i]));
      |                         ^~~~~~~
main.c:12:25: note: include '<ctype.h>' or provide a declaration of 'toupper'
main.c:13:17: error: implicit declaration of function 'isupper' [-Wimplicit-function-declaration]
   13 |         else if(isupper(t[i]))
      |                 ^~~~~~~
main.c:13:17: note: include '<ctype.h>' or provide a declaration of 'isupper'
main.c:14:25: error: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
   14 |             printf("%c",tolower(t[i]));
      |                         ^~~~~~~
main.c:14:25: note: include '<ctype.h>' or provide a declaration of 'tolower'
Language: C

#include <stdio.h>
#include <string.h>
char t[100000];
int main(){
    int i;
    int n;
    gets(t);
    n=strlen(t);
    for(i=0;i<n;i++){
        if(islower(t[i])) printf("%c",toupper(t[i]));
        else if(isupper(t[i])) printf("%c",tolower(t[i]));
        else printf("%c",t[i]);
    }
    puts("");
    return 0;
}



Compiler output:
main.c: In function 'main':
main.c:7:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    7 |     gets(t);
      |     ^~~~
      |     fgets
main.c:10:12: error: implicit declaration of function 'islower' [-Wimplicit-function-declaration]
   10 |         if(islower(t[i])) printf("%c",toupper(t[i]));
      |            ^~~~~~~
main.c:3:1: note: include '<ctype.h>' or provide a declaration of 'islower'
    2 | #include <string.h>
  +++ |+#include <ctype.h>
    3 | char t[100000];
main.c:10:39: error: implicit declaration of function 'toupper' [-Wimplicit-function-declaration]
   10 |         if(islower(t[i])) printf("%c",toupper(t[i]));
      |                                       ^~~~~~~
main.c:10:39: note: include '<ctype.h>' or provide a declaration of 'toupper'
main.c:11:17: error: implicit declaration of function 'isupper' [-Wimplicit-function-declaration]
   11 |         else if(isupper(t[i])) printf("%c",tolower(t[i]));
      |                 ^~~~~~~
main.c:11:17: note: include '<ctype.h>' or provide a declaration of 'isupper'
main.c:11:44: error: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
   11 |         else if(isupper(t[i])) printf("%c",tolower(t[i]));
      |                                            ^~~~~~~
main.c:11:44: note: include '<ctype.h>' or provide a declaration of 'tolower'
Language: C


#include <stdio.h>
#include <string.h>
char t[100000];
int main(){
    int i;
    int n;
    gets(t);
    n=strlen(t);
    for(i=0;i<n;i++){
        if(islower(t[i])) printf("%c",toupper(t[i]));
        else if(isupper(t[i])) printf("%c",tolower(t[i]));
        else printf("%c",t[i]);
    }
    puts("");
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:8:5: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    8 |     gets(t);
      |     ^~~~
      |     fgets
main.c:11:12: error: implicit declaration of function 'islower' [-Wimplicit-function-declaration]
   11 |         if(islower(t[i])) printf("%c",toupper(t[i]));
      |            ^~~~~~~
main.c:4:1: note: include '<ctype.h>' or provide a declaration of 'islower'
    3 | #include <string.h>
  +++ |+#include <ctype.h>
    4 | char t[100000];
main.c:11:39: error: implicit declaration of function 'toupper' [-Wimplicit-function-declaration]
   11 |         if(islower(t[i])) printf("%c",toupper(t[i]));
      |                                       ^~~~~~~
main.c:11:39: note: include '<ctype.h>' or provide a declaration of 'toupper'
main.c:12:17: error: implicit declaration of function 'isupper' [-Wimplicit-function-declaration]
   12 |         else if(isupper(t[i])) printf("%c",tolower(t[i]));
      |                 ^~~~~~~
main.c:12:17: note: include '<ctype.h>' or provide a declaration of 'isupper'
main.c:12:44: error: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
   12 |         else if(isupper(t[i])) printf("%c",tolower(t[i]));
      |                                            ^~~~~~~
main.c:12:44: note: include '<ctype.h>' or provide a declaration of 'tolower'
Language: C

#include <stdio.h>

int main(void)
{
	char s[1201];
	int i;
	gets(s);
	for(i=0;s[i]!='\0';i++){
		if('a'<=s[i]&&s[i]<='z')s[i]-='a'-'A';
		else if('A'<=s[i]&&s[i]<='Z')s[i]+='a'-'A';
	}
	puts(s);
	return 0;
}


Compiler output:
main.c: In function 'main':
main.c:7:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    7 |         gets(s);
      |         ^~~~
      |         fgets
Language: C

#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>

int main(void)
{
	char s[1201];
	int i;
	gets(s);
	for(i=0;s[i]!='\0';i++){
		if('a'<=s[i]&&s[i]<='z')s[i]-='a'-'A';
		else if('A'<=s[i]&&s[i]<='Z')s[i]+='a'-'A';
	}
	puts(s);
	return 0;
}


Compiler output:
main.c: In function 'main':
main.c:8:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    8 |         gets(s);
      |         ^~~~
      |         fgets
Language: C


 #include <stdlib.h> 
 int main()
 { 
     char buf[1250]; char *p, c; 
     gets(buf); p = buf; while (*p) { c = *p++;
     if (isupper(c)) c = tolower(c);
     else if (islower(c)) c = toupper(c); 
     putchar(c); 
         
     }
     putchar('\n'); 
     return 0;
     } 




Compiler output:
main.c: In function 'main':
main.c:6:6: error: implicit declaration of function 'gets' [-Wimplicit-function-declaration]
    6 |      gets(buf); p = buf; while (*p) { c = *p++;
      |      ^~~~
main.c:7:10: error: implicit declaration of function 'isupper' [-Wimplicit-function-declaration]
    7 |      if (isupper(c)) c = tolower(c);
      |          ^~~~~~~
main.c:3:1: note: include '<ctype.h>' or provide a declaration of 'isupper'
    2 |  #include <stdlib.h>
  +++ |+#include <ctype.h>
    3 |  int main()
main.c:7:26: error: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
    7 |      if (isupper(c)) c = tolower(c);
      |                          ^~~~~~~
main.c:7:26: note: include '<ctype.h>' or provide a declaration of 'tolower'
main.c:8:15: error: implicit declaration of function 'islower' [-Wimplicit-function-declaration]
    8 |      else if (islower(c)) c = toupper(c);
      |               ^~~~~~~
main.c:8:15: note: include '<ctype.h>' or provide a declaration of 'islower'
main.c:8:31: error: implicit declaration of function 'toupper' [-Wimplicit-function-declaration]
    8 |      else if (islower(c)) c = toupper(c);
      |                               ^~~~~~~
main.c:8:31: note: include '<ctype.h>' or provide a declaration of 'toupper'
main.c:9:6: error: implicit declaration of function 'putchar' [-Wimplicit-function-declaration]
    9 |      putchar(c);
      |      ^~~~~~~
main.c:3:1: note: include '<stdio.h>' or provide a declaration of 'putchar'
    2 |  #include <stdlib.h>
  +++ |+#include <stdio.h>
    3 |  int main()
Language: C


 #include <stdlib.h> 
 int main()
 { 
     char buf[1250];
 char *p, c; 
     gets(buf);
 p = buf; 
while (*p)
 {
 c = *p++;
     if (isupper(c)) c = tolower(c);
     else if (islower(c)) c = toupper(c); 
     putchar(c); 
         
     }
     putchar('\n'); 
     return 0;
     } 




Compiler output:
main.c: In function 'main':
main.c:7:6: error: implicit declaration of function 'gets' [-Wimplicit-function-declaration]
    7 |      gets(buf);
      |      ^~~~
main.c:12:10: error: implicit declaration of function 'isupper' [-Wimplicit-function-declaration]
   12 |      if (isupper(c)) c = tolower(c);
      |          ^~~~~~~
main.c:3:1: note: include '<ctype.h>' or provide a declaration of 'isupper'
    2 |  #include <stdlib.h>
  +++ |+#include <ctype.h>
    3 |  int main()
main.c:12:26: error: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
   12 |      if (isupper(c)) c = tolower(c);
      |                          ^~~~~~~
main.c:12:26: note: include '<ctype.h>' or provide a declaration of 'tolower'
main.c:13:15: error: implicit declaration of function 'islower' [-Wimplicit-function-declaration]
   13 |      else if (islower(c)) c = toupper(c);
      |               ^~~~~~~
main.c:13:15: note: include '<ctype.h>' or provide a declaration of 'islower'
main.c:13:31: error: implicit declaration of function 'toupper' [-Wimplicit-function-declaration]
   13 |      else if (islower(c)) c = toupper(c);
      |                               ^~~~~~~
main.c:13:31: note: include '<ctype.h>' or provide a declaration of 'toupper'
main.c:14:6: error: implicit declaration of function 'putchar' [-Wimplicit-function-declaration]
   14 |      putchar(c);
      |      ^~~~~~~
main.c:3:1: note: include '<stdio.h>' or provide a declaration of 'putchar'
    2 |  #include <stdlib.h>
  +++ |+#include <stdio.h>
    3 |  int main()
Language: C

#include <stdio.h> 
 #include <ctype.h> 
 #include <stdlib.h>
 int main() { char buf[1250];
 char *p, c; 
 gets(buf);
 p = buf;
 while (*p) { c = *p++; 
 if (isupper(c)) c = tolower(c);
 else if (islower(c)) c = toupper(c); 
 putchar(c); 
     
 }
 putchar('\n');
 return 0; 
     
 } 


Compiler output:
main.c: In function 'main':
main.c:6:2: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 |  gets(buf);
      |  ^~~~
      |  fgets
Language: C

include <stdio.h>
#include <ctype.h>
int main(void){
  int c;
  while((c=getchar())!=EOF){
      if(isupper(c)){
          putchar(tolower(c));
      }
      else if(islower(c)){
          putchar(toupper(c));
      }
      else{
          putchar(c);
      }
  }
  return 0;  
}


Compiler output:
main.c:1:9: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    1 | include <stdio.h>
      |         ^
main.c: In function 'main':
main.c:5:12: error: implicit declaration of function 'getchar' [-Wimplicit-function-declaration]
    5 |   while((c=getchar())!=EOF){
      |            ^~~~~~~
main.c:3:1: note: 'getchar' is defined in header '<stdio.h>'; this is probably fixable by adding '#include <stdio.h>'
    2 | #include <ctype.h>
  +++ |+#include <stdio.h>
    3 | int main(void){
main.c:5:24: error: 'EOF' undeclared (first use in this function)
    5 |   while((c=getchar())!=EOF){
      |                        ^~~
main.c:5:24: note: 'EOF' is defined in header '<stdio.h>'; this is probably fixable by adding '#include <stdio.h>'
main.c:5:24: note: each undeclared identifier is reported only once for each function it appears in
main.c:7:11: error: implicit declaration of function 'putchar' [-Wimplicit-function-declaration]
    7 |           putchar(tolower(c));
      |           ^~~~~~~
main.c:7:11: note: include '<stdio.h>' or provide a declaration of 'putchar'
Language: C

#include <stdio.h>

char toUPPER(char c);
char toLOWER(char c);

int main(void){
  char text[1200];
  gets(text);
  for(int i=0; text[i] != '\0'; i++){
    if (text[i] >= 'a' && text[i] <= 'z') text[i] = toUPPER(text[i]);
    else if (text[i] >= 'A' && text[i] <= 'Z') text[i] = toLOWER(text[i]);
  }
  printf("%s\n", text);
  return 0;
}


char toUPPER(char c){
  if (c >= 'a' && c <= 'z'){
    return (c - 0x20);
  }else{
    return c;
  }
}

char toLOWER(char c){
  if (c >= 'A' && c <= 'Z'){
    return (c + 0x20);
  }else{
    return c;
  }
}



Compiler output:
main.c: In function 'main':
main.c:8:3: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    8 |   gets(text);
      |   ^~~~
      |   fgets
Language: C

#include <stdio.h>

char toUPPER(char c);
char toLOWER(char c);

int main(void){
  char text[1200];
  gets(text);
  for(int i=0; text[i] != '\0'; i++){
    if (text[i] >= 'a' && text[i] <= 'z') text[i] = toUPPER(text[i]);
    else if (text[i] >= 'A' && text[i] <= 'Z') text[i] = toLOWER(text[i]);
  }
  printf("%s\n", text);
  return 0;
}


char toUPPER(char c){
  if (c >= 'a' && c <= 'z'){
    return (c - 0x20);
  }else{
    return c;
  }
}

char toLOWER(char c){
  if (c >= 'A' && c <= 'Z'){
    return (c + 0x20);
  }else{
    return c;
  }
}




Compiler output:
main.c: In function 'main':
main.c:8:3: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    8 |   gets(text);
      |   ^~~~
      |   fgets
Language: C

#include<stdio.h>
#include <ctype.h>
#include <stdlib.h>

int main()
{
 char buf[1250];
 char *p, c;

 gets(buf);
 p = buf;
 while (*p) {
 c = *p++;
 if (isupper(c)) c = tolower(c);
 else if (islower(c)) c = toupper(c);
 putchar(c);
 }

 putchar('\n');

 return 0;
}


Compiler output:
main.c: In function 'main':
main.c:10:2: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   10 |  gets(buf);
      |  ^~~~
      |  fgets
Language: C


#include <stdio.h>
#include <ctype.h>
#include <stdlib.h>

int main()
{
	char buf[1250];
	char *p, c;

	gets(buf);
	p = buf;
	while (*p) {
		c = *p++;
		if (isupper(c)) c = tolower(c);
		else if (islower(c)) c = toupper(c);
		putchar(c);
	}
	putchar('\n');
	return 0;
}


Compiler output:
main.c: In function 'main':
main.c:11:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   11 |         gets(buf);
      |         ^~~~
      |         fgets
Language: C


#include <stdio.h>
#include <ctype.h>
#include <stdlib.h>

int main()
{
	char buf[1250];
	char *p, c;

	gets(buf);
	p = buf;
	while (*p) {
		c = *p++;
		if (isupper(c)) c = tolower(c);
		else if (islower(c)) c = toupper(c);
		putchar(c);
	}
	putchar('\n');
	return 0;
}



Compiler output:
main.c: In function 'main':
main.c:11:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   11 |         gets(buf);
      |         ^~~~
      |         fgets
Language: C


#include <stdio.h>
#include <ctype.h>
#include <stdlib.h>

int main()
{
	char buf[1250];
	char *p, c;

	gets(buf);
	p = buf;
	while (*p) {
		c = *p++;
		if (isupper(c)) c = tolower(c);
		else if (islower(c)) c = toupper(c);
		putchar(c);
	}
	putchar('\n');
	return 0;
}




Compiler output:
main.c: In function 'main':
main.c:11:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
   11 |         gets(buf);
      |         ^~~~
      |         fgets
Language: C

#include<stdio.h>
int main(){
	char ch;
	while(1){
		scanf("%c", &ch);
		if ('a' <= ch && ch <= 'z') {
			ch -= 32;
		}else if('A' <= ch && ch <= 'Z') {
			ch += 32;
		}
		if(ch == '\n') break;
		printf("%c", ch);
	}
	printf("\n");
}gir


Compiler output:
main.c:15:1: error: expected '=', ',', ';', 'asm' or '__attribute__' at end of input
   15 | }gir
      | ^
Language: C

#include <stdio.h>
int main() {
	char m[1200];
	char h[1200];
	int i, n = 0;
	while (1) {
		scanf_s("%c", &m[n]);
		if (m[n] == '\n')
			break;
		h[n] = m[n];
		if (h[n] >= 'A' && h[n] <= 'Z')
			m[n] = h[n] + 32;
		else if (h[n] >= 'a' && h[n] <= 'z')
			m[n] = h[n] - 32;
		n++;
	}
	for (i = 0; i<n; i++)
		printf("%c", m[i]);
	printf("\n");
}
 


Compiler output:
main.c: In function 'main':
main.c:7:17: error: implicit declaration of function 'scanf_s'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    7 |                 scanf_s("%c", &m[n]);
      |                 ^~~~~~~
      |                 scanf
Language: C

#include <stdio.h>
#include <ctype.h>
int main(){
 char m[1200];
 char h[1200];
 int i,n=0;
 while(1){
  scanf("%c",&m[n]);
  if(m[n]=='\n')
   break;
  if(islower(m[n]))
   h[n]=m[n]+32;
  else if(isupper(m[n]))
   h[n]=m[n]-32;
  else
   h[n]=m[n];
  n++;}
 for(i=0;i<n;i++)
  printf("%c",h[i])
 printf("\n");
 return 0;
}
   


Compiler output:
main.c: In function 'main':
main.c:19:20: error: expected ';' before 'printf'
   19 |   printf("%c",h[i])
      |                    ^
      |                    ;
   20 |  printf("\n");
      |  ~~~~~~
Language: C

#include <stdio.h>
#include <ctype.h>
int main(){
 char c;
 while(1){
  scanf("%c",&c);
  if(islower(c))
   printf("%c",toupper(c));
  else if(isupper(c))
   printf("%c",tolower(c));
  else
   printf("%c",c);
  if(%c=='\n')
   break;}
 return 0;
}


Compiler output:
main.c: In function 'main':
main.c:13:6: error: expected expression before '%' token
   13 |   if(%c=='\n')
      |      ^
Language: C

#include <stdio.h>

	gets(buf);
	p = buf;
	while (*p) {
		c = *p++;
		if (isupper(c)) c = tolower(c);
		else if (islower(c)) c = toupper(c);
		putchar(c);
	}
	putchar('\n');
	return 0;
}



Compiler output:
main.c:3:9: warning: data definition has no type or storage class
    3 |         gets(buf);
      |         ^~~~
main.c:3:9: error: type defaults to 'int' in declaration of 'gets' [-Wimplicit-int]
main.c:3:9: error: parameter names (without types) in function declaration [-Wdeclaration-missing-parameter-type]
main.c:4:9: warning: data definition has no type or storage class
    4 |         p = buf;
      |         ^
main.c:4:9: error: type defaults to 'int' in declaration of 'p' [-Wimplicit-int]
main.c:4:13: error: 'buf' undeclared here (not in a function)
    4 |         p = buf;
      |             ^~~
main.c:5:9: error: expected identifier or '(' before 'while'
    5 |         while (*p) {
      |         ^~~~~
main.c:11:17: error: expected declaration specifiers or '...' before '\xa'
   11 |         putchar('\n');
      |                 ^~~~
main.c:12:9: error: expected identifier or '(' before 'return'
   12 |         return 0;
      |         ^~~~~~
main.c:13:1: error: expected identifier or '(' before '}' token
   13 | }
      | ^
Language: C

#include <stdio.h>

int main(void)
{
	char buf[1250];
	char *p, c;

	gets(buf);
	p = buf;
	while (*p) {
		c = *p++;
		if (isupper(c)) c = tolower(c);
		else if (islower(c)) c = toupper(c);
		putchar(c);
	}
	putchar('\n');
	return 0;
}



Compiler output:
main.c: In function 'main':
main.c:8:9: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    8 |         gets(buf);
      |         ^~~~
      |         fgets
main.c:12:21: error: implicit declaration of function 'isupper' [-Wimplicit-function-declaration]
   12 |                 if (isupper(c)) c = tolower(c);
      |                     ^~~~~~~
main.c:2:1: note: include '<ctype.h>' or provide a declaration of 'isupper'
    1 | #include <stdio.h>
  +++ |+#include <ctype.h>
    2 | 
main.c:12:37: error: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
   12 |                 if (isupper(c)) c = tolower(c);
      |                                     ^~~~~~~
main.c:12:37: note: include '<ctype.h>' or provide a declaration of 'tolower'
main.c:13:26: error: implicit declaration of function 'islower' [-Wimplicit-function-declaration]
   13 |                 else if (islower(c)) c = toupper(c);
      |                          ^~~~~~~
main.c:13:26: note: include '<ctype.h>' or provide a declaration of 'islower'
main.c:13:42: error: implicit declaration of function 'toupper' [-Wimplicit-function-declaration]
   13 |                 else if (islower(c)) c = toupper(c);
      |                                          ^~~~~~~
main.c:13:42: note: include '<ctype.h>' or provide a declaration of 'toupper'
Language: C

#include<iostream>
using namespace std;

int main(){
	char a;
	while(true) {
		a = cin.get();
		if ( a>='A' && a<='Z' ) {
			a+='a'-'A';
		}else if ( a>='a' && a<='z' ) {
			a+='A'-'a';
		}
		cout << a;
		if ( a == '\n' ) break;
	}
    return 0;
}

Compiler output:
main.c:1:9: fatal error: iostream: No such file or directory
    1 | #include<iostream>
      |         ^~~~~~~~~~
compilation terminated.
Language: C

#include <iostream>
#include <cctype>
 
using namespace std;
 
int main() {
    int i,j;
    char buf;
    
    while(1){
        cin.get(buf);
        
        //???????????¶
        if ( buf == '\n' ) break;
        
        if(islower(buf)) cout << (char)toupper(buf);
        else if(isupper(buf)) cout << (char)tolower(buf);
        else cout << buf;
    }
    
        return 0;
}

Compiler output:
main.c:1:10: fatal error: iostream: No such file or directory
    1 | #include <iostream>
      |          ^~~~~~~~~~
compilation terminated.
Language: C

#include<stdio.h>

int main(int argc, char* argv[])
{
  char c;
  while((c = getcahr()) != '\n'){
    if(('a' <= c && c <= 'z')||('A' <= c && c <= 'Z')){
      if('a' <= c && c <= 'z'){
        putchar('A' + (c - 'a'));
      }else{
        putchar('a' + (c - 'A'));
      }
    }else{
       putchar(c);
    }
  }
  return(0);
}

Compiler output:
main.c: In function 'main':
main.c:6:14: error: implicit declaration of function 'getcahr'; did you mean 'getchar'? [-Wimplicit-function-declaration]
    6 |   while((c = getcahr()) != '\n'){
      |              ^~~~~~~
      |              getchar
Language: C

#include <stdio.h> int main(void){    int count=0,n=0;    char a[5000],b[5000];    gets(a);       for(n=0;n<5000;n++)    {        if(count>=5)        {            b[n-5]='\0';        }                 if(a[n]>='A'&&a[n]<='Z')        {            b[n]=a[n]+32;            count=0;        }                 else if(a[n]>='a'&&a[n]<='z')        {            b[n]=a[n]-32;            count=0;        }             else if(a[n]==',')        {            b[n]=',';        }        else if(a[n]==' ')        {            b[n]=' ';            count++;        }        else if(a[n]=='.')        {            b[n]='.';        }         else        {            b[n]=a[n];        }             }    puts(b);return 0;  }

Compiler output:
main.c:1:20: warning: extra tokens at end of #include directive
    1 | #include <stdio.h> int main(void){    int count=0,n=0;    char a[5000],b[5000];    gets(a);       for(n=0;n<5000;n++)    {        if(count>=5)        {            b[n-5]='\0';        }                 if(a[n]>='A'&&a[n]<='Z')        {            b[n]=a[n]+32;            count=0;        }                 else if(a[n]>='a'&&a[n]<='z')        {            b[n]=a[n]-32;            count=0;        }             else if(a[n]==',')        {            b[n]=',';        }        else if(a[n]==' ')        {            b[n]=' ';            count++;        }        else if(a[n]=='.')        {            b[n]='.';        }         else        {            b[n]=a[n];        }             }    puts(b);return 0;  }
      |                    ^~~
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include <bits/stdc++.h>
using namespace std;

int main(void){
	char word;

	while(1){
		scanf("%c", &word);
		if(word == '\n') break;
		if(word >= 'a' && word <= 'z'){
			word -= 'a' - 'A';
		}else if(word >= 'A' && word <= 'Z'){
			word += 'a' - 'A';
		}

		printf("%c", word);
	}
	puts("");

	return 0;
}

Compiler output:
main.c:1:10: fatal error: bits/stdc++.h: No such file or directory
    1 | #include <bits/stdc++.h>
      |          ^~~~~~~~~~~~~~~
compilation terminated.
Language: C

#include<stdio.h>
int main()
{
	char c;
	for(;~scanf("%c",&c);putchar(64<c&&c<91?c+32:94<c&&c<121?c-32:c));
　　　　return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:1: error: stray '\343' in program
    6 | <U+3000><U+3000><U+3000><U+3000>return 0;
      | ^~~~~~~~
main.c:6:3: error: stray '\343' in program
    6 | <U+3000><U+3000><U+3000><U+3000>return 0;
      |         ^~~~~~~~
main.c:6:5: error: stray '\343' in program
    6 | <U+3000><U+3000><U+3000><U+3000>return 0;
      |                 ^~~~~~~~
main.c:6:7: error: stray '\343' in program
    6 | <U+3000><U+3000><U+3000><U+3000>return 0;
      |                         ^~~~~~~~
Language: C++

#include <iostream>
using namespace std;
int main(void){
	char c;
	while(1){
    	scanf("%c",&c);
    	if(isalpha(c) ){
    		if(%c,isupper(c) ) printf(%c , c);
    		else if(%c,islower(c) )printf(%c , c);
    	}else printf(%c , c);

    	if(c == '\n') break;
	}
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:20: error: expected primary-expression before '%' token
    8 |                 if(%c,isupper(c) ) printf(%c , c);
      |                    ^
a.cc:8:43: error: expected primary-expression before '%' token
    8 |                 if(%c,isupper(c) ) printf(%c , c);
      |                                           ^
a.cc:9:25: error: expected primary-expression before '%' token
    9 |                 else if(%c,islower(c) )printf(%c , c);
      |                         ^
a.cc:9:47: error: expected primary-expression before '%' token
    9 |                 else if(%c,islower(c) )printf(%c , c);
      |                                               ^
a.cc:10:22: error: expected primary-expression before '%' token
   10 |         }else printf(%c , c);
      |                      ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(void){
	char c;
	while(1){
    	scanf("%c",&c);
    	if(isalpha(c) ){
    		if(%c,isupper(c) ) printf(%c , c);
    		else if(%c,islower(c) )printf(%c , c);
    	}else printf(%c , c);

    	if(c == '\n') break;
	}
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:20: error: expected primary-expression before '%' token
    8 |                 if(%c,isupper(c) ) printf(%c , c);
      |                    ^
a.cc:8:43: error: expected primary-expression before '%' token
    8 |                 if(%c,isupper(c) ) printf(%c , c);
      |                                           ^
a.cc:9:25: error: expected primary-expression before '%' token
    9 |                 else if(%c,islower(c) )printf(%c , c);
      |                         ^
a.cc:9:47: error: expected primary-expression before '%' token
    9 |                 else if(%c,islower(c) )printf(%c , c);
      |                                               ^
a.cc:10:22: error: expected primary-expression before '%' token
   10 |         }else printf(%c , c);
      |                      ^
Language: C++

#include<stdio.h>
#include<string.h>
 
int main(void){
 
  int i;
 
  
  char str[101];
 
  
  while(1){
  scanf("%c", &str);
  if(str=='\n') break;

  
  for(i=0;i<=strlen(str);i++){
    
    if(str[i]>=97&&str[i]<=122)
       str[i]=str[i]-32;
    
  
    else if(str[i]>=65&&str[i]<=90)
      str[i]=str[i]+32;
  }
 
  
  printf("%s", str);
  
  }

 printf("\n");
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:9: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   14 |   if(str=='\n') break;
      |      ~~~^~~~~~
Language: C++

#include <iostream>
#include <cctype>
#include <stdio.h>
using namespace std;
 
int main() {
    char a;
    while(1) {
         
        scanf("%c", &a);
        if(a == '\n') break;
        if(islower(a)){
            printf("%c", toupper(a));
        }
        else if (isupper(a)) {
            printf("%c", tolower(a));
        }
        else {
            printf("%c",a);
        }
         
    }
    cout << endl;
     
    


Compiler output:
a.cc: In function 'int main()':
a.cc:23:18: error: expected '}' at end of input
   23 |     cout << endl;
      |                  ^
a.cc:6:12: note: to match this '{'
    6 | int main() {
      |            ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    char str[1000],ch;
    int i=0,j;
    gets(str);
    while(str[i]!='\0')    //untill Enter has been Clicked..
    {
        ch=str[i];
        if(ch>='A' && ch<='Z')
        {
            //strlwr(str);
            //lowerCase(str);
            str[i]=str[i]+32;
            //cout<<"Data "<<str[i]<<endl;
        }
        else if(ch>='a' && ch<='z')
        {
            //strupr(str);
            //upperCase(str);
            str[i]=str[i]-32;
        }
        i++;
    }
    //cout<<str<<endl;
    printf("%s\n",str);

}



Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |     gets(str);
      |     ^~~~
      |     getw
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    char str[1201],ch;
    int i=0,j;
    gets(str);
    while(str[i]!='\0')    //untill Enter has been Clicked..
    {
        ch=str[i];
        if(ch>='A' && ch<='Z')
        {
            //strlwr(str);
            //lowerCase(str);
            str[i]=str[i]+32;
            //cout<<"Data "<<str[i]<<endl;
        }
        else if(ch>='a' && ch<='z')
        {
            //strupr(str);
            //upperCase(str);
            str[i]=str[i]-32;
        }
        i++;
    }
    //cout<<str<<endl;
    printf("%s\n",str);

}



Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |     gets(str);
      |     ^~~~
      |     getw
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    char str[1200],ch;
    int i=0,j;
    gets(str);
    while(str[i]!='\0')    //untill Enter has been Clicked..
    {
        ch=str[i];
        if(ch>='A' && ch<='Z')
        {
            //strlwr(str);
            //lowerCase(str);
            str[i]=str[i]+32;
            //cout<<"Data "<<str[i]<<endl;
        }
        else if(ch>='a' && ch<='z')
        {
            //strupr(str);
            //upperCase(str);
            str[i]=str[i]-32;
        }
        i++;
    }
    //cout<<str<<endl;
    printf("%s\n",str);

}



Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |     gets(str);
      |     ^~~~
      |     getw
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    char str[1199],ch;
    int i=0,j;
    gets(str);
    while(str[i]!='\0')    //untill Enter has been Clicked..
    {
        ch=str[i];
        if(ch>='A' && ch<='Z')
        {
            //strlwr(str);
            //lowerCase(str);
            str[i]=str[i]+32;
            //cout<<"Data "<<str[i]<<endl;
        }
        else if(ch>='a' && ch<='z')
        {
            //strupr(str);
            //upperCase(str);
            str[i]=str[i]-32;
        }
        i++;
    }
    //cout<<str<<endl;
    printf("%s\n",str);

}



Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |     gets(str);
      |     ^~~~
      |     getw