To get the full benefit of the lesson, watch the video
Lesson 8: The cin statement
NOTE: for a fast copy, follow these steps in order:
- Click anywhere in a text box below (result will be a blinking vertical line in the text box)
- Hit ctrl + A on the key board (the "ctrl + A" means hit Ctrl and A at the same time)
(The result should be that all the text inside the text box lights up in blue)
- Hit Ctrl + C (Nothing significantly happens that is visible) and now its copied to the clipboard and your ready to paste it anywhere
you wish
The cin statement allows the user to enter a value for x in this example
notice that the cin.get() statement is replaced by the system("pause") because the cin.get() will not work once cin has been called. (i
don't know why that is the case)
Here is another example. Computers don't like to divide by zero, you can try to input 0 for y to see what happens or you can also find
out what happens by watching the video.
thanks for help...
ReplyDeleteVery good work! Great help to students.
ReplyDeletedude ur vids on youtube is awesome i really really really really really really aprreciate it
ReplyDelete