Esempio n. 1
0
        static void Main(string[] args)
        {
            MyDictionary <int, string> myDictionary = new MyDictionary.MyDictionary <int, string>();

            myDictionary.Add(10, "Buket");
            myDictionary.Add(15, "Ceylin");
            myDictionary.Add(20, "Bertan");
            myDictionary.Add(25, "Gülsevim");
            myDictionary.Add(30, "Bülent");

            myDictionary.ListAllValue();
            Console.WriteLine("********");
            myDictionary.ListValueByKey(20);
            myDictionary.ListValueByKey(10);
        }
Esempio n. 2
0
        static void Main(string[] args)
        {
            MyDictionary <int, string> ogrenci = new MyDictionary.MyDictionary <int, string>();

            ogrenci.Add(17, "Tunahan");
            ogrenci.Add(34, "İlyas");
            ogrenci.Add(78, "Özcan");


            Console.WriteLine($" Öğrencinin Numarası: {ogrenci.No[0]} \n Öğrencinin İsmi: {ogrenci.Isım[0]} \n ******************************** ");
            Console.WriteLine($" Öğrencinin Numarası: {ogrenci.No[1]} \n Öğrencinin İsmi: {ogrenci.Isım[1]} \n ********************************");
            Console.WriteLine($" Öğrencinin Numarası: {ogrenci.No[2]} \n Öğrencinin İsmi: {ogrenci.Isım[2]} \n ******************************** ");

            Console.ReadLine();
        }