Дата активности | Консольный раздел | Прогресс | ||
---|---|---|---|---|
2020-02-08 | task1 | Цифры | 75 % | |
2019-02-06 | task1 | Целые задачи | 100 % | |
2019-01-20 | task1 | Геометрия | 100 % | |
2019-01-18 | task1 | Символы | 100 % | |
2019-01-17 | task1 | Формулы | 100 % | |
2019-01-16 | task1 | Лирика | 86 % | |
2019-01-15 | task1 | Целые числа | 100 % | |
2019-01-14 | task1 | Строки | 100 % | |
2019-01-02 | task1 | Семантика | 100 % | |
Итого: | 95 % |
Console.WriteLine((Convert.ToInt32(Console.ReadLine()))*10+5000+5);
using System;
class VideoSharp
{
static void Main()
{
int num=Convert.ToInt32(Console.ReadLine());
int i = num % 10;
int j = num / 1000;
if (j > i)
{
Console.WriteLine(num - 1000 * (j - i) + (j - i));
}
else Console.WriteLine(num + 1000 * (i-j) - (i-j));
}
}
Console.WriteLine(Convert.ToInt32(Console.ReadLine().Remove(2, 1)));
int A=int.Parse(Console.ReadLine());
int eggs=(int)(A/5)*A;
Console.WriteLine(eggs);
А почему нельзя сделать так: string[]k=Console.ReadLine().Split("*");
Console.WriteLine(int.Parse(k[0])*int.Parse(k[1])); ?
double k=double.Parse(Console.ReadLine());
Console.WriteLine("{0:f2}",Math.Sin(Math.PI/(180/k)));
string []c=Console.ReadLine().Split();
int square=(int.Parse(c[3])-int.Parse(c[1]))*(int.Parse(c[2])-int.Parse(c[0]));
Console.WriteLine(square);
string v="Visaginas";
string sum="";
for(int i=0; i<v.Length; i++)
{
sum+=Convert.ToInt32(v[i])+" ";
}
Console.WriteLine(sum);
string[]bottles=Console.ReadLine().Split();
short A=short.Parse(bottles[0]);
short B=short.Parse(bottles[1]);
Console.WriteLine((A*25+12*B+5*2+10*5)/40);
int N = int.Parse(Console.ReadLine());
int eggs = N * (int)(N/1.5);
Console.WriteLine(eggs);
Глупо, что нельзя использовать тру/фолс, ведь, насколько я понял, в одной из перегрузок с помощью тру/фолс можно выбрать будет ли учитываться регистр при проверке.
Console.WriteLine(Console.ReadLine().ToLower()==Console.ReadLine().ToLower());
string[]strs=Console.ReadLine().Split();
for(int i=0; i<strs.Length; i++)
Console.WriteLine(strs[i]);
using System;
class VideoSharp
{
static void Main()
{
string [] i=Console.ReadLine().Split();
string [] j=Console.ReadLine().Split();
string [] k=Console.ReadLine().Split();
string [] l=Console.ReadLine().Split();
string [] a=Console.ReadLine().Split();
Console.WriteLine(i[i.Length-1]+" "+j[j.Length-1]+" "+k[k.Length-1]+" "+l[l.Length-1]+" "+a[a.Length-1]);
Console.WriteLine(int.Parse(i[i.Length-1])+int.Parse(j[j.Length-1])+int.Parse(k[k.Length-1])+int.Parse(l[l.Length-1])+int.Parse(a[a.Length-1]));
}
}
В тесте 005 все время таймаут, как это работает? В предыдущей задачи так же было(
using System;
class VideoSharp
{
static void Main()
{
string [] Arr=Console.ReadLine().Split();
int result=0;
for(int i=0; i<5; i++)
result+=int.Parse(Arr[i]);
Console.WriteLine(result);
}