본문 바로가기

YYYEJI

검색하기
YYYEJI
프로필사진 YEJI ⍢

  • 분류 전체보기 (437)
    • C (0)
    • AI (8)
    • Dart (6)
    • Note (0)
    • Java (58)
    • Linux (14)
    • Flutter (12)
    • Github (9)
    • Python (54)
    • Security (7)
    • Network (0)
    • Algorithm (8)
    • Extensions (2)
    • News scrap (1)
    • Data structure (18)
    • R programming (11)
    • Database & SQL (17)
    • Operating system (4)
    • Computer architectures (84)
    • Web Application Server (WAS.. (37)
    • HTML(or XML) & CSS & JavaSc.. (68)
    • 인공지능 챗봇 (19)
Guestbook
Notice
Recent Posts
Recent Comments
Link
250x250
«   2026/01   »
일 월 화 수 목 금 토
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 29 30 31
Tags
  • mysql
  • javascript
  • Class
  • computer
  • DATAPATH
  • function
  • DB
  • system
  • github
  • instruction
  • Java
  • Rag
  • DS
  • Linux
  • for
  • python
  • php
  • html
  • data structure
  • control
  • react
  • web
  • architecture
  • XML
  • openai
  • AI
  • MIPS
  • Pipelining
  • CSS
  • Algorithm
more
Archives
Today
Total
관리 메뉴
  • 글쓰기
  • 방명록
  • RSS
  • 관리

목록Conditional (1)

YYYEJI

[JAVA] 조건부 연산자(Conditional operator)

조건부 연산자(Conditional operator)란? If-else 문을 간결하게 해 놓은 코드입니다. Variable_name = (Boolean_Expression) ? Result1 : Result2 ; public static void main(String[] args) { int num = 2; System.out.print("The number is " + ((num%2==0) ? "positive" : "negative")); } 조건문에 맞춰서 결과가 true이면 Result1, 결과가 false이면 Result2가 실행됩니다. ◡̈

Java 2022. 12. 24. 17:46
이전 Prev 1 Next 다음

Blog is powered by kakao / Designed by Tistory

티스토리툴바