How can I print a string to the console without a newline at the end?

后端 未结 4 556
臣服心动
臣服心动 2020-12-11 15:51

My question is.

what is it you type when you want your answer next to your question in c#

I mean like this but you type the answer next to the question.

4条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-11 16:41

    string product;
    
    Console.Write("What is the product you want?");
    
    product = Console.ReadLine(); 
    

提交回复
热议问题