library conio.h in C language for Ubuntu

5

I'm programming in C in Ubuntu's Codeblock. I'm trying to add a conio.h library. During several searches I found a site that for reasons of incompatibility in ubuntu with the conio.h library, a group created gconio.h. So I should download a file on this site called gconio.h and save it to the folder (/ usr / include), but my Ubuntu is not allowing me to save or copy and paste in that folder. Can anyone help me understand why?

Website that I quoted above: link

    
asked by anonymous 10.10.2015 / 22:09

2 answers

6

conio.h is not part of the default C language library. In fact, it was programmed to be used in MS-DOS, however you probably want to use the ncurses , which is basically a conio.h for Linux.

    
10.10.2015 / 22:22
2

You do not have permissions to put the file in the folder. To do this you must go to where you downloaded gconio.h and run the following command sudo cp gconio.h /usr/include/gconio.h .

You will be prompted for the root password to enter and press enter.

Or you can use ncurses as already suggested.

    
11.10.2015 / 01:03