Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- #include<string.h>
- #include<strings.h>
- int main() {
- int i;
- char *name;
- /*
- int i;
- char *str;
- fprintf(stderr,"Are you sure you want to delete:: [y/n]:");
- scanf("%s",str);
- if(strcmp(str,"y") == 0) {
- fprintf(stderr,"Success\n");
- }
- else {
- fprintf(stderr,"Fail\n");
- }
- return(0);
- */
- fprintf(stderr, "Enter your name:[y/n] " );
- scanf("%s", name );
- if( strcmp( name,"y") == 0 ){
- printf( "PASS!\n" );
- i=10;
- }
- else
- printf("FAIL\n");
- printf("i is --> %d\n",i);
- }
Add Comment
Please, Sign In to add comment