I am trying to write a program to access the name from user and print each of element and it address but can't figure out what happen to my code. If Gcc compiler not support Conio.h library so what should i do? Can I write a program without using conio.h library?. Please explain it
Here is my code:
//Write a program to find each of string element and it location
#include <stdio.h>
#include<conio.h>
int main(){
char name[10];
int i = 0;
printf("Please enter your name: ");
scanf("%s", name);
while(name[i] != '\0'){
printf("%c is located at %u", name[i], &name[i]);
i++;
}
getch();
return 0;
}
Output: No such file or directory
complination terminated