fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. // your code goes here
  5. return 0;
  6. }
  7.  
Success #stdin #stdout 0s 5280KB
stdin
using System;

class Program
{
    static void Main(string[] args)
    {
        // ประกาศตัวแปรสำหรับเก็บข้อมูล
        string number, code, movieName;
        int quantity;
        double price, total;

        // รับค่าข้อมูลจากผู้ใช้
        Console.WriteLine("****************************");
        Console.WriteLine("Program Video");
        Console.WriteLine("****************************");

        Console.Write("Number      = ");
        number = Console.ReadLine();

        Console.Write("Code        = ");
        code = Console.ReadLine();

        Console.Write("Movie Name  = ");
        movieName = Console.ReadLine();

        Console.Write("Quantity    = ");
        quantity = int.Parse(Console.ReadLine());

        Console.Write("Price       = ");
        price = double.Parse(Console.ReadLine());

        // คำนวณผลรวม
        total = quantity * price;

        // แสดงผลลัพธ์
        Console.WriteLine("****************************");
        Console.WriteLine("Total       = " + total);
        Console.WriteLine("****************************");

        Console.WriteLine("Press any key to exit...");
        Console.ReadKey();
    }
}
stdout
Standard output is empty