В чем отличие | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

В чем отличие

В чем разница? Console.WriteLine("hello world"); И Console.Write("hello world");

15th Mar 2018, 4:44 PM
MaS1o
MaS1o - avatar
2 Answers
+ 2
В первом случае курсор будет перенесён на следующую строку, во втором - нет
15th Mar 2018, 4:48 PM
Evil Dog
Evil Dog - avatar
0
The difference is: Console.WriteLine("hello world"); // inserts a newline character after printing the text // in other word it will print the text and then jump to the next line Console.Write("hello world"), // prints the text passed in but does not jump to the next line.
15th Mar 2018, 5:10 PM
Ulisses Cruz
Ulisses Cruz - avatar