-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathProgram.cs
More file actions
54 lines (46 loc) · 2.29 KB
/
Program.cs
File metadata and controls
54 lines (46 loc) · 2.29 KB
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// Задача 19. Напишите пргограмму, которая принимает на вход пятизначное число и проверяет, явлвется ли оно полиндромом
// Console.WriteLine("Введите пятизначное число");
// int num = Convert.ToInt32(Console.ReadLine());
// int ost1 = num%100;
// System.Console.WriteLine(ost1);
// int ost2 = ost1/10;
// System.Console.WriteLine(ost2);
// int ost3 = ost1%10;
// System.Console.WriteLine(ost3);
// int first = num/1000;
// System.Console.WriteLine(first);
// int first2 = first/10;
// System.Console.WriteLine(first2);
// int first3 = first%10;
// System.Console.WriteLine(first3);
// if ((ost2 == first3)&&(ost3 == first2))
// {
// System.Console.WriteLine("POLINDROM");
// }
// else
// {
// System.Console.WriteLine("NO");
// }
// Задача 21. Напишите программу, которая на вход принимает на вход координаты двух точек и находит расстояние между ними в 3д пространстве
// Console.WriteLine("Введите координату x1 = ");
// int X1 = Convert.ToInt32(Console.ReadLine());
// Console.WriteLine("Введите координату y1 = ");
// int Y1 = Convert.ToInt32(Console.ReadLine());
// Console.WriteLine("Введите координату z1 = ");
// int Z1 = Convert.ToInt32(Console.ReadLine());
// Console.WriteLine("Введите координату x2 = ");
// int X2 = Convert.ToInt32(Console.ReadLine());
// Console.WriteLine("Введите координату y2 = ");
// int Y2 = Convert.ToInt32(Console.ReadLine());
// Console.WriteLine("Введите координату z2 = ");
// int Z2 = Convert.ToInt32(Console.ReadLine());
// double AA = Math.Sqrt(Math.Pow((X2-X1), 2) + Math.Pow((Y2-Y1),2) + Math.Pow((Z2-Z1),2));
// System.Console.WriteLine(AA);
// Задача 23. Напишите программу, которая принимает на вход число (N) и выдаёт таблицу кубов от 1 до N.
// Console.WriteLine("Введите число");
// int num = Convert.ToInt32(Console.ReadLine());
// for (int i = 1; i <= num; i++)
// {
// System.Console.Write(Math.Pow(i,3));
// System.Console.Write(" ");
// }