Answers for "out of bounds error"

0

error in array

#include <stdio.h>
int main()
{
	char a[20],b[10]= "String",c[8]={'S','t','r','i','n','g','\0'};
	int i;
	for(i=0;c[i]!='\0';i++){
	
	printf("%c",&c[i]);}
	printf("%s",b);
    puts(b);
    	printf("enter the string first scanf and then gets");
    	scanf("%s",a);
    	gets(a);
}#include <stdio.h>
int main()
{
	char a[20],b[10]= "String",c[8]={'S','t','r','i','n','g','\0'};
	int i;
	for(i=0;c[i]!='\0';i++){
	
	printf("%c",&c[i]);}
	printf("%s",b);
    puts(b);
    	printf("enter the string first scanf and then gets");
    	scanf("%s",a);
    	gets(a);
}
Posted by: Guest on April-28-2020

Code answers related to "out of bounds error"

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language