All pastes #2107982 Raw Edit

Something

public text v1 · immutable
#2107982 ·published 2012-01-31 04:30 UTC
rendered paste body
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("Lütfen 1 ile 10 arasında bir tahminde bulunun");
            int tutulanSayi;
            int tahmin;
            Random sayiTutucu = new Random();
            do
            {
                tutulanSayi = sayiTutucu.Next(1, 11);
                string girilenDeger = Console.ReadLine();
                tahmin = int.Parse(girilenDeger);
                if (tahmin == tutulanSayi)
                {
                    Console.WriteLine("Tebrikler Tahmininiz Doğru.");
                    Console.Read();
                }
                else
                {
                    if (tahmin < tutulanSayi)
                    {
                        Console.WriteLine("Daha yüksek bir değer girmelisiniz. Lütfen tekrar deneyin.");
                    }
                    else
                    {
                        Console.WriteLine("Daha düşük bir değer girmelisiniz. Lütfen tekrar deneyin.");
                    }
                }
            } while (tutulanSayi != tahmin);
        }
    }
}