본문 바로가기

개발/델파이

[2일차(1/2)] Hello Delphi!!

델파이에서는 대소문자 구분이 없음


선언( : )


str : String / num : Integer


대입( = )


str := 'Hello Wrold'; / num := 10;


변수이름은 알파벳, 숫자, _만 사용 가능

변수이름의 시작은 알파벳만 가능


주석

// 한줄 주석

(* 두줄

이상의 주석 *)


예) 

program hello;

uses SysUtils;

 Procedure helloworld();

   begin

   WriteLn('Hello World');

   end;

      begin

      helloworld();

      end;


이제 시작~!



파일 -> new -> window vcl application -delphi



오른쪽에 있는 TButton을 왼쪽으로 드래그 엔 드롭




버튼을 더블클릭 하면 켜지는 창에 

ShowMessage('hello delphi'); 입력



상단에 디버그 버튼을 누르면! 실행!!

버튼을 클릭하면 아까 입력한 hello delphi가 똭!



굳!!