'프로그래밍'에 해당되는 글 605건

  1. 2008.02.13 Visual C++ 2005 Express Edition로 Win32 어플리케이션 만들기
  2. 2008.02.12 Hello 예제 for Ruby
  3. 2008.02.12 Hello 예제 for Python
  4. 2008.02.12 Hello 예제 for Groovy
  5. 2008.02.11 Hello 예제 for Lua

Visual C++ 2005 Express Edition에서 Win32어플리케이션을
만들기위해서는 몇가지 설정을 해주어야된다.

1) 먼저 Visual C++ 2005 Express Edition 다운로드해서 셋업한다.

2) Microsoft Platform SDK를 다운로드해서 셋업한다.

3) 패스를 설정한다.
  Visual C++ 2005 Express Edition을 시작해서 툴 > 옵션 > 프로젝트 및 솔루션 > VC++ 디렉토리에
  Microsoft Platform SDK의 Bin, Includem lib의 패스를 추가한다.

4) 라이브러리 추가
  C:\Program Files\Microsoft Visual Studio 8\VC\VCProjectDefaults
     \corewin_express.vsprops의 AdditionalDependencies의 kernel32.dll의 뒤에
  반각 스페이스를 넣어서 user32.lib gdi32.lib winspool.lib comdlg32.dll advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib 를 추가한다.

5) Win32 템플레이트의 유효화
  C:\Program Files\Microsoft Visual Studio 8\VC\VCWizards\AppWiz\Generic
     \Application\html\1041\AppSettings.htm

    //WIN_APP.disabled=true;
    //WIN_APP_LABEL.disabled=true;
    //DLL_APP.disabled=true;
    //DLL_APP_LABEL.disabled=tu\rue;

  위의 네줄을 코멘트처리한다.

6) 개발환경을 재기동하면 Visual C++ 2005 Express Edition에서 Win32 어플리케이션을
  만들 수 있게된다.

Posted by Scripter
,
컨솔에 문자 출력하는 ruby 구문은

       print "문자열(스트링)\n"

이다. 여기서 "\n"은 개행을 위해 추가된 개행(newline) 문자이다.
(JRuby의 문자 출력 구문도 위와 같다.)
 
소스 파일명: hello.rb
------------------------------[소스 시작]
print "Hello, world!\n"
------------------------------[소스 끝]

실행> ruby hello.rb
Hello, world!
Posted by Scripter
,
컨솔에 문자 출력하는 python 구문은

       print "문자열(스트링)"

이다. 여기서 개행문자 "\n"은 추가하지 않아도 된다.
(Jython의 문자 출력 구문도 위와 같다.)
 
소스 파일명: hello.py
------------------------------[소스 시작]
print "Hello, world!"
------------------------------[소스 끝]

실행> python hello.py
Hello, world!


* Jython으로 실행하는 경우:

실행> jython hello.py
Hello, world!


* IronPython으로 실행하는 경우:

실행> ipy hello.py
Hello, world!

Posted by Scripter
,
컨솔에 문자 출력하는 Groovy 구문은

       println "문자열(스트링)"

       print "문자열(스트링)"

이다. println 구문은 개행 문자 "\n" 없이 개행하지만,
print 구문은 개행 문자 "\n"를 추가해야 개행한다.
 
소스 파일명: hello.groovy
------------------------------[소스 시작]
println "Hello, world!"
------------------------------[소스 끝]

실행> groovy hello.groovy
Hello, world!

Posted by Scripter
,
컨솔에 문자 출력하는 lua 구문은

       print "문자열(스트링)"

이다. 여기서 개행문자 "\n"은 추가하지 않아도 된다.
 
소스 파일명: hello.lua
------------------------------[소스 시작]
print "Hello, world!"
------------------------------[소스 끝]

실행> lua hello.lua
Hello, world!

Posted by Scripter
,