Задание 1.
int a,b;
scanf("%i", &a);
scanf("%i", &b);
if (a<b)
for(int i=a; i<=b; i++)
printf("x = ", x , "; y = ", ((x3+1)/(x-3)+x) );
Задание 2.
int sum;
sum = 0;
for(int i=1; i<=115; i+=6)
sum+=i;
printf(sum);
Задание 3.
int a,b, n;
n = 0;
scanf("%i", &a);
scanf("%i", &b);
if (a<b)
for(int i=a; i<=b; i++)
if (i%11 == 0) n++;
if (a>b)
for(int i=b; i<=a; i++)
if (i%11 == 0) n++;
printf(n);
На C ничего никогда не писал, поэтому может чё-то не так, но по идее как-то так...
begin
writeln('1: ',(sqrt(10)+1)/(6.25-1.8*1.8));
writeln('2: ',sin(5)/cos(5)*10*sqrt(19));
writeln('3: ',100*sin(4));
writeln('4: ',sin(cos(1))/0.25);
writeln('5: ',exp(sin(3))*ln(2));
writeln('6: ',sqrt(sqrt(5)+sqrt(6)));
writeln('7: ',(sqrt(3)+2*sqrt(2))/sqrt(sqrt(5)));
writeln('8: ',(exp(sin(3))*ln(2)+exp(sin(2))*ln(2))/(exp(2.4)*ln(4)+1));
end.
Результат:
1: 1.38281649839481
2: -147.353232893516
3: -75.6802495307928
4: 2.0575810340942
5: 0.798202533367663
6: 2.16461491269994
7: 3.04977540329462
8: 0.0980510445730408
Подробнее - на -
Объяснение:
import java.util.Scanner;
class Main {
public static void main(String[] args)
{
Scanner input = new Scanner (System.in);
System.out.println ("Let's play the lottery!");
System.out.println ("Enter an integer from 0 to 100");
boolean won = false;
int x = 0;
x = input.nextInt ();
if (x > 100)
{
System.out.println ("You entered a number outside the specified limits!");
System.out.println ("Enter a new number");
x = input.nextInt ();
}
if (x < 0)
{
System.out.println ("You entered a number outside the specified limits!");
System.out.println ("Enter a new number");
x = input.nextInt ();
}
if (x == 10)
{
System.out.println ("You are lucky. You won 100$");
won = true;
}
if (x == 50)
{
System.out.println ("Luck is always with you. You won 10$");
won = true;
}
if (x == 99)
{
System.out.println ("Good job. You won 50$");
won = true;
}
if (x == 1)
{
System.out.println ("The winning is 20$");
won = true;
}
if (!won)
{
System.out.println("You are not lucky. Try next time");
}
System.out.println ("End!");
}
}
Объяснение: