본문 바로가기
KDT/C# 프로그래밍

HelloWorld

by 잰쟁 2023. 7. 19.
728x90
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace HelloWorld
{
    internal class Program
    {
        static void Main(string[] args)
        {
            //변수를 선언하고 값을 할당 (변수의 초기화)
            string characterName = "홍길동";
            Console.Write("이름: ");
            Console.WriteLine(characterName);

            
            int level; //변수의 정의, 선언
            level = 12; //값을 level이라는 이름의 변수에 저장 (값을 할당)
            Console.Write("레벨: ");
            Console.WriteLine(level);
        }
    }
}

'KDT > C# 프로그래밍' 카테고리의 다른 글

스타크래프트 (마린 vs 저그)  (0) 2023.07.20
디아블로 아이템4  (0) 2023.07.19
디아블로 아이템3  (0) 2023.07.19
디아블로 아이템2  (0) 2023.07.19
디아블로 아이템1  (0) 2023.07.19