当前位置:网站首页>Can Console. Clear be used to only clear a line instead of whole console?
Can Console. Clear be used to only clear a line instead of whole console?
2022-07-04 12:41:00 【Rich in starch】
problem :
While working on a question/answer program for school, it occurred to me that I can use Console.Clear()
to wipe out everything on the screen. When writing a question and answer program for the school , It suddenly occurred to me that I could use Console.Clear()
Clear everything on the screen .I wonder if I can use Console.Readline(valueOne)
, then output only the answer without the question. I want to know if I can use Console.Readline(valueOne)
, Then only output the answers without questions .If I only asked one question, the Console.Clear
works. If I only ask one question , Console.Clear
Work .
I have several questions with values not references, to erase if possible. I have a few questions about values rather than references , If possible , Please delete .I want to leave out the questions and only display several answers. I want to omit these questions , Show only a few answers .I think if I store the answers, I could use Console.Clear()
then just Console.WriteLine()
with three variables. I think if I store answers , I can use Console.Clear()
Then use only with three variables Console.WriteLine()
.I could do something like this: I can do such things :
Console.WriteLine("Value 1 is: {0:c}" + "Value 2 is: {1:c}" + "Value 3 is: {2:c}, valueOne, valueTwo, valueThree).
The problem is easier with references because the values are stored and retrieved. It's easier to quote questions , Because values are stored and retrieved .If I simply use methods to pass by value and output the value, main()
will not have a reference to those values to clear and output again. If I just use methods to pass and output values by value , be main()
There will be no reference to these values to clear and output again .That's why I wonder if I can just ask a question, then erase the line and output only the answer (or answers). That's why I want to know if I can only ask one question , Then erase the line and output only the answer ( Or the answer ).
I am just trying to understand the possibilities and not trying to setup a program. I just want to know the possibility , Instead of trying to set up the program .I like to know the abilities of outputting a value from reference and by value without extra output questions. I want to know the ability to output values by reference and by value , Without additional output problems .
Solution :
Reference resources : https://stackoom.com/en/question/bXTM边栏推荐
- [Yunju entrepreneurial foundation notes] Chapter II entrepreneur test 23
- The solution of permission denied
- Guava ImmutableSet. Builder source code analysis, shift original code, complement code, reverse code review
- VBA, JSON interpretation, table structure -json string conversion
- How to use the mongodb ID array to get multiple documents- How to get multiple document using array of MongoDb id?
- ArcGis利用栅格处理工具进行影像裁剪
- [Yunju entrepreneurial foundation notes] Chapter II entrepreneur test 18
- Paper notes ACL 2020 improving event detection via open domain trigger knowledge
- Clockwise rotation method of event arrangement -- PHP implementation
- Leetcode day 17
猜你喜欢
[Yunju entrepreneurial foundation notes] Chapter II entrepreneur test 20
Entitas learning [3] multi context system
Detailed explanation of NPM installation and caching mechanism
16.内存使用与分段
DC-5靶机
Complementary knowledge of auto encoder
nn. Exploration and experiment of batchnorm2d principle
Daily Mathematics Series 57: February 26
Jetson TX2配置Tensorflow、Pytorch等常用库
Flet教程之 02 ElevatedButton高级功能(教程含源码)(教程含源码)
随机推荐
How to disable debug messages on sockjs stomp - how to disable debug messages on sockjs Stomp
Star leap plan | new projects are continuously being recruited! MSR Asia MSR Redmond joint research program invites you to apply!
VBA, JSON interpretation, table structure -json string conversion
priority_ queue
IPv6 experiment
BCD code Baidu Encyclopedia
R语言--readr包读写数据
Kivy tutorial 08 countdown app implements timer call (tutorial includes source code)
C语言:围圈报号排序问题
Langue C: trouver le nombre de palindromes dont 100 - 999 est un multiple de 7
Hongke case study on storm impact in coastal areas of North Carolina using lidar
[directory] search
Unity performance optimization reading notes - Introduction (1)
Uva536 binary tree reconstruction tree recovery
[solve the error of this pointing in the applet] SetData of undefined
Show recent errors only command /bin/sh failed with exit code 1
Introduction to random and threadlocalrandom analysis
Tableau makes data summary after linking the database, and summary exceptions occasionally occur.
DC-5靶机
C language array