Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace SmallShop
- {
- class Program
- {
- static void Main(string[] args)
- {
- //goods array
- string[] goods = { "coffee", "water", "beer", "sweets", "peanuts" };
- //cities array
- string[] cities = { "Sofia", "Plovdiv", "Varna" };
- //prices array
- double[] prices = { 0.40, 0.45, 0.50, 0.70, 0.80, 1.10, 1.15, 1.20, 1.30, 1.35, 1.45, 1.50, 1.55, 1.60 };
- //indexes..........(.0..,..1..,..2..,..3..,..4..,..5..,..6..,..7..,..8..,..9..,..10.,..11.,..12.,..13..)
- //quantity
- int quantity = int.Parse(Console.ReadLine());
- //conditions
- if ((goods == "coffee") && (cities == "Sofia"))
- {
- Console.WriteLine(prices[2]);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement