'전체 글'에 해당되는 글 43건

  1. 2019.09.26 swich 문(7)
  2. 2019.09.26 swich 문(6)
  3. 2019.09.26 swich 문(5)
  4. 2019.09.26 swich 문(4)
  5. 2019.09.26 swich 문(3)
  6. 2019.09.26 swich 문 (2)
  7. 2019.09.26 swich 문 (1)
  8. 2019.09.25 10998 A x B
  9. 2019.09.25 1001 A-B
  10. 2019.09.25 1000 A+B

swich 문(7)

Console/실습 2019. 9. 26. 11:14
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
Console.WriteLine("Edge,Chrome,Firefox,Safari,Opera 중 입력해주세요.");
            string a = Console.ReadLine();
            switch (a)
            {
                
                case "Firefox":
                case "Safari":
                case "Chrome":
                    Console.WriteLine("Available");
                    break;
                case "Opera":
                case "Edge":
                    Console.WriteLine("Not available");
                    break;
            }
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > 실습' 카테고리의 다른 글

swich 문(9)  (0) 2019.09.26
swich 문(8)  (0) 2019.09.26
swich 문(6)  (0) 2019.09.26
swich 문(5)  (0) 2019.09.26
swich 문(4)  (0) 2019.09.26

swich 문(6)

Console/실습 2019. 9. 26. 11:12
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
Console.WriteLine("1에서 7사이 숫자를 입력해주세요.");
            int a = Int32.Parse(Console.ReadLine());
            switch (a)
            {
                case 1:
                    Console.WriteLine("Monday");
                    break;
                case 2:
                    Console.WriteLine("Tuesday");
                    break;
                case 3:
                    Console.WriteLine("Wednesday");
                    break;
                case 4:
                    Console.WriteLine("Thursday");
                    break;
                case 5:
                    Console.WriteLine("Friday");
                    break;
                case 6:
                    Console.WriteLine("Saturday");
                    break;
                case 7:
                    Console.WriteLine("Sunday");
                    break;
                default:
                    Console.WriteLine("다시 입력하세요.");
                    break;
            }
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > 실습' 카테고리의 다른 글

swich 문(8)  (0) 2019.09.26
swich 문(7)  (0) 2019.09.26
swich 문(5)  (0) 2019.09.26
swich 문(4)  (0) 2019.09.26
swich 문(3)  (0) 2019.09.26

swich 문(5)

Console/실습 2019. 9. 26. 11:11
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
 string a = Console.ReadLine();
            switch (a)
            {
                case "#FFFF00":
                    Console.WriteLine("YELLO");
                    break;
                case "#000000":
                    Console.WriteLine("BLACK");
                    break;
                case "#FF0000":
                    Console.WriteLine("RED");
                    break;
                case "#0000FF":
                    Console.WriteLine("BLUE");
                    break;
                case "#00FF00":
                    Console.WriteLine("GREEN");
                    break;
                case "#00AC00":
                    Console.WriteLine("NONE");
                    break;
                default:
                    Console.WriteLine("다시 입력해주세요.");
                    break;
 

'Console > 실습' 카테고리의 다른 글

swich 문(7)  (0) 2019.09.26
swich 문(6)  (0) 2019.09.26
swich 문(4)  (0) 2019.09.26
swich 문(3)  (0) 2019.09.26
swich 문 (2)  (0) 2019.09.26

swich 문(4)

Console/실습 2019. 9. 26. 11:09
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
Console.WriteLine("다음 중 통일신라 시대의 도읍은 어디인지 알맞은 정답을 찾아 입력하세요.");
            Console.WriteLine("1. 평양");
            Console.WriteLine("2. 서라벌");
            Console.WriteLine("3. 개성");
            Console.WriteLine("4. 한양");
            Console.WriteLine("5. 전주");
            int a = Int32.Parse(Console.ReadLine());
            switch (a)
            {
                case 1:
                    Console.WriteLine("틀렸습니다. 통일신라의 도읍은 평양이 아닙니다.");
                    break;
                case 2:
                    Console.WriteLine("정답입니다. 통일신라의 도읍은 서라벌 입니다.");
                    break;
                case 3:
                    Console.WriteLine("틀렸습니다. 통일신라의 도읍은 개성이 아닙니다.");
                    break;
                case 4:
                    Console.WriteLine("틀렸습니다. 통일신라의 도읍은 한양이 아닙니다.");
                    break;
                case 5:
                    Console.WriteLine("틀렸습니다. 통일신라의 도읍은 전주가 아닙니다.");
                    break;
                default:
                    Console.WriteLine("1~7중에 입력해주세요.");
                    break;
            }
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > 실습' 카테고리의 다른 글

swich 문(6)  (0) 2019.09.26
swich 문(5)  (0) 2019.09.26
swich 문(3)  (0) 2019.09.26
swich 문 (2)  (0) 2019.09.26
swich 문 (1)  (0) 2019.09.26

swich 문(3)

Console/실습 2019. 9. 26. 11:08
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
            switch (n)
            {
                case 1:
                case 3:
                case 5:
                case 7:
                case 8:
                case 10:
                case 12:
                    Console.WriteLine(31);
                    break;
                case 4:
                case 6:
                case 9:
                case 11:
                    Console.WriteLine(30);
                    break;
                case 2:
                    Console.WriteLine(28);
                    break;
                case 15:
                    Console.WriteLine(-1);
                    break;
                default:
                    Console.WriteLine("재 입력 바람");
                    break;
            }
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > 실습' 카테고리의 다른 글

swich 문(5)  (0) 2019.09.26
swich 문(4)  (0) 2019.09.26
swich 문 (2)  (0) 2019.09.26
swich 문 (1)  (0) 2019.09.26
알람 시계  (0) 2019.09.25

swich 문 (2)

Console/실습 2019. 9. 26. 11:06
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
string i = (Console.ReadLine());
            switch (i)
            {
                case "A":
                    {
                        Console.WriteLine("90~100");
                        break;
                    }
                case "B":
                    {
                        Console.WriteLine("80~89");
                        break;
                    }
                case "C":
                    {
                        Console.WriteLine("70~79");
                        break;
                    }
                case "D":
                    {
                        Console.WriteLine("60~69");
                        break;
                    }
                default:
                    Console.WriteLine("0");
                    break;
 
            }
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > 실습' 카테고리의 다른 글

swich 문(4)  (0) 2019.09.26
swich 문(3)  (0) 2019.09.26
swich 문 (1)  (0) 2019.09.26
알람 시계  (0) 2019.09.25
상품 목록(3)  (0) 2019.09.23

swich 문 (1)

Console/실습 2019. 9. 26. 11:04
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
            int a = Int32.Parse(Console.ReadLine());
            switch (a)
            {
                case 1:
                    {
                        Console.WriteLine("안녕하세요");
                        break;
                    }
                case 2:
                    {
                        Console.WriteLine("반갑습니다");
                        break;
                    }
                default:
                    {
                        Console.WriteLine("감사합니다.");
                        break;
                    }
            }
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > 실습' 카테고리의 다른 글

swich 문(3)  (0) 2019.09.26
swich 문 (2)  (0) 2019.09.26
알람 시계  (0) 2019.09.25
상품 목록(3)  (0) 2019.09.23
상품 목록(2)  (0) 2019.09.23

10998 A x B

Console/Algorithm 2019. 9. 25. 16:49
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
 
namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            string input = Console.ReadLine();
            string[] input1 = input.Split();
            int a = int.Parse(input1[0]);
            int b = int.Parse(input1[1]);
            Console.WriteLine(a * b);
        }
    }
}
 
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > Algorithm' 카테고리의 다른 글

1008 A/B  (0) 2019.09.27
9655 돌 게임  (0) 2019.09.26
1001 A-B  (0) 2019.09.25
1000 A+B  (0) 2019.09.25
10718 강한친구 대한육군  (0) 2019.09.25

1001 A-B

Console/Algorithm 2019. 9. 25. 16:46
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
 
namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            string input = Console.ReadLine();
            string[] input1 = input.Split();
            int a = int.Parse(input1[0]);
            int b = int.Parse(input1[1]);
            Console.WriteLine(a - b);
        }
    }
}
 
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > Algorithm' 카테고리의 다른 글

9655 돌 게임  (0) 2019.09.26
10998 A x B  (0) 2019.09.25
1000 A+B  (0) 2019.09.25
10718 강한친구 대한육군  (0) 2019.09.25
2557 Hello World!  (0) 2019.09.25

1000 A+B

Console/Algorithm 2019. 9. 25. 16:43
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
 
namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            string input = Console.ReadLine();
            string[] input1 = input.Split();
            int a = int.Parse(input1[0]);
            int b = int.Parse(input1[1]);
            Console.WriteLine(a + b);
        }
    }
}
 
http://colorscripter.com/info#e" target="_blank" style="color:#e5e5e5text-decoration:none">Colored by Color Scripter
 

'Console > Algorithm' 카테고리의 다른 글

9655 돌 게임  (0) 2019.09.26
10998 A x B  (0) 2019.09.25
1001 A-B  (0) 2019.09.25
10718 강한친구 대한육군  (0) 2019.09.25
2557 Hello World!  (0) 2019.09.25