0

How to get the keyboard input in C++

Somebody know how to get the keyboard input

14th Nov 2024, 4:02 PM
Eder Prin
Eder Prin - avatar
4 Respostas
+ 1
In the Code Bits area, you are prompted for input when you hit run. ALL input must be provided in that box. If you want multiple lines of input, put the information on separate lines, like this. One Two Three Then when the program runs, those lines are pushed to your app. Once your program starts, you cannot interact with it. All inputs must be sent in advance. This is true for all code bits programs except for the web editor.
14th Nov 2024, 4:13 PM
Jerry Hobby
Jerry Hobby - avatar
+ 1
Eder Prin , your profild shows that you have already finished the `introduction to c++` tutorial. you also have done a working codebit that uses input and output with c++. > so it is not clear what your issues is. please link your current attempt here to get help from the community.
14th Nov 2024, 8:13 PM
Lothar
Lothar - avatar
0
I don't know do you think about: std::cin >> ? you don't need std when you use that namespace
14th Nov 2024, 6:14 PM
Mihaly Nyilas
Mihaly Nyilas - avatar
0
or maybe you mean keyboard event? Things you would be interested in if yoou're creating a cli, gui or keylogger... These are usually system specific because of the libraries you would need. for windows: https://learn.microsoft.com/en-us/windows/win32/learnwin32/keyboard-input
15th Nov 2024, 1:38 AM
Bob_Li
Bob_Li - avatar