블로그 이미지
생각처럼

카테고리

전체보기 (209)
TOOL (1)
다이어리 (1)
Bit (200)
HELP? (0)
Total
Today
Yesterday

달력

« » 2025.2
1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28

공지사항

태그목록

최근에 올라온 글

using System;
public class SumTest
{
 public int a = 0;
 public int b = 0;
 int total = 0;
 public void PrintM()
 {
  Console.WriteLine("{0}",total);
 }
 public int Sum(int a,int b)
 {
  total = a+b;
  return total;
 }
}

csc /t:library /out:SumTest.dll SumTest.cs //SumTest.cs 파일로 SumTest.dll 을 생성

using System;

class SumTestMain
{
    public static void Main(String[] args)
    {
  SumTest st = new SumTest();
  Console.WriteLine("두수를 입력하세요");
  st.a = Int32.Parse(Console.ReadLine());
  st.b = Int32.Parse(Console.ReadLine());
  int sum = st.Sum(st.a,st.b);
  st.PrintM();

 }
}


csc /r:SumTest.dll SumTestMain.cs //SumTest.dll 을 참조하여 컴파일 한다

Posted by 생각처럼
, |

최근에 달린 댓글

최근에 받은 트랙백

글 보관함