Console.ReadLine()
문자열만 입력받을 수 있음 - 숫자 로쓰기 위해서는 문자열을 숫자로 바꿔줘야 함
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Practice_input {
internal class Program {
static void Main(string[] args) {
//Console.ReadLine(); 한줄 입력 받음
string input = Console.ReadLine();
Console.WriteLine("input : " + input);
}
}
}
'C# > C# 연습' 카테고리의 다른 글
Operation : 연산자 (0) | 2022.11.28 |
---|---|
Data Type Casting : 자료형 변환 (0) | 2022.11.27 |
Variable : 변수 (0) | 2022.11.27 |
MaxValue 와 MinValue (0) | 2022.11.26 |
기초 연습 01 (0) | 2022.11.25 |