Randomize words
using System;
using [Link];
using [Link];
namespace clasesss
{
class Program
{
static void Main(string[] args)
{
string[] input = [Link]().Split().ToArray();
Random randomNum = new Random();
for(int i = 0; i< [Link]; i++)
{
int place = [Link](0,[Link]);
string position1 = input[place];
string position2 = input[i];
input[place] = position2;
input[i] = position1;
}
foreach(string word in input)
{
[Link](word);
}
}
}
}
Days of week
using System;
using [Link];
using [Link];
namespace DayOfWeek
{
class Program
{
static void Main(string[] args)
{
string dateString = [Link]();
DateTime date = [Link](dateString, "dd-MM-yyyy", null);
[Link]([Link]);
}
}
}
Factorial
using System;
using [Link];
namespace Factorial
{
class Program
{
static void Main(string[] args)
{
int n = [Link]([Link]());
BigInteger result = Factorial(n);
[Link](result);
}
static BigInteger Factorial(int n)
{
BigInteger result = 1;
for (int i = 1; i <= n; i++)
{
result *= i;
}
return result;
}
}
}
Rectangle class
using System;
class Rectangle
{
public int Width { get; set; }
public int Height { get; set; }
public string Color { get; set; }
public Rectangle(int width, int height, string color)
{
Width = width;
Height = height;
Color = color;
}
public int CalculateArea()
{
return Width * Height;
}
}
class Program
{
static void Main(string[] args)
{
int width = [Link]([Link]());
int height = [Link]([Link]());
string color = [Link]();
Rectangle rectangle = new Rectangle(width, height, color);
int area = [Link]();
[Link]($"Rect({[Link]}, {[Link]}, {[Link]}) has
area {area}.");
}
}