Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
Tags
- Pigpen Cipher
- base16
- 비즈네르 암호
- cookie
- Caesar Cipher
- Javscript
- Linux
- base32
- reversing
- Python
- aslr
- Fortran 90
- assembly
- AVR
- php_extract
- 시저 암호
- sha1
- vigenere cipher
- Web Hacking
- overthewire
- Navajo alphabet
- Masonic Cipher
- BASE64
- Qrcode
- burpsuit
- 카이사르 암호
- Mail Header injection
- JavaScript
- webhacking
- sql injection
Archives
- Today
- Total
My Drive
05. Decisions 본문
1. If (single-statement)
◦ example :
if(x.gt.0.) x=sqrt(x)
2. If (block)
◦ example :
if(x.gt.0.) then
x=sqrt(x)
y=y-x
endif
3. If-Then-Else ( end if == endif )
◦ example :
if(x.lt.0.) then
write(*,*) ’x is negative’
else
if(x.gt.0.) then
write(*,*) ’x is positive’
else
write(*,*) ’x must be zero’
endif
endif
4. If-Then-Elseif- ... - Else - Endif ( else if == elseif )
◦ example :
if(x.lt.0.) then
write(*,*) ’x is negative’
elseif(x.gt.0.) then
write(*,*) ’x is positive’
else
write(*,*) ’x must be zero’
endif
5. Case ( integer, logical, character )
◦ example :
read(*,*) i
select case(i)
case(1)
write(*,*) ’excellent’
case(2,3)
write(*,*) ’OK’
case(4:6)
write(*,*) ’shame on you’
case default
write(*,*) ’impossible’
end select
'programming' 카테고리의 다른 글
07. Arrays (0) | 2014.10.27 |
---|---|
06. Input / Output (0) | 2014.10.27 |
04. Loops (0) | 2014.10.25 |
03. Expressions (0) | 2014.10.25 |
02. Data types (자료형) (0) | 2014.10.24 |
Comments