Xkg shokolot A so’m turadi va Ykg konfet B so’m turadi 1,5kg shokolot 1,5 kg konfetdan qanchaga qimmat turishini aniqlovchi programma tuzilsin
using System;
namespace Mardonov Izzatillo.
{
class Program
{
static void Main(string[] args)
{
double s, k,a,b,q;
Console.Write("SHokolotni narxini kiritig=");
s = Convert.ToDouble(Console.ReadLine ());
Console.Write("SHokolotni og'irligi kiritig=");
a= Convert.ToDouble(Console.ReadLine());
Console.Write("Konfetni narxini kiritig=");
k = Convert.ToDouble(Console.ReadLine());
Console.Write("Konfetni og'irligi kiritig=");
b= Convert.ToDouble(Console.ReadLine());
q = a * s -b * k;
Console.Write("SHokolotni narxi Konfetning narxidan "+q+" qimmat");
}
}
}
Do'stlaringiz bilan baham: |