السبت، 10 نوفمبر 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication7
{
    class Program
    {
        static void Main(string[] args)
        {
            double rsistor;
            double volt, I;
            int a=0;
            int d=0;
            while (a++ < 6){
            
                Console.WriteLine("plz enter the value rsistor");
                rsistor = double.Parse(Console.ReadLine());

                Console.WriteLine("plz enter the value volt");
                volt = double.Parse(Console.ReadLine());
                I = volt / rsistor;
                if (I >= 2)  {
                    d++;
                }
            }
                Console.WriteLine("the digital of times I>=2 is" + d);
            

     
           Console.ReadKey();
        }
    }
}

الاثنين، 5 نوفمبر 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication20
{
    class Program
    {
        static void Main(string[] args)
        {
            int x;
            int z = 0;
            Console.WriteLine(" plz enter the num");
            x = int.Parse(Console.ReadLine());

            while (x!=0)
            {

                z++;
                x = x / 10;
            }
            Console.WriteLine(" The num of digits is = " + z);


            Console.ReadKey();
        }

    }
}

الاثنين، 22 أكتوبر 2018

using System;



using System.Collections.Generic;



using System.Linq;



using System.Text;



using System.Threading.Tasks;




namespace ConsoleApplication2
{



    class Program
    {


        static void Main(string[] args)
        {


            int a, c, b;

            int e = 0;
            int y = 0;
            int x = 0;
            int num = 1;

            while (num++ < 5)
            {


                Console.WriteLine("plz enter the first num  ");



                a = int.Parse(Console.ReadLine());

                Console.WriteLine("plz enter  the second num  ");



                b = int.Parse(Console.ReadLine());




                if (a > b)
                {
                    Console.WriteLine("the first num bigger than the second num  ");
                  
                    e++;

                }




                else if (a == b)
                {
                    Console.WriteLine("the first num equel the second num  ");
                    
                    x++;

                }


                else
                {
                    Console.WriteLine("the second num bigger than the first num  ");
                 

                    y++;

                }


            }


            Console.WriteLine("the times that a>b = " + e);
            Console.WriteLine("the times that a<b = " + y);
            Console.WriteLine("the times that a=b = " + x);
            Console.ReadKey();
        }


    }
}

السبت، 20 أكتوبر 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication9
{
    class Program
    {
        static void Main(string[] args)
        {
            int num = 0;
            while(++num < 6)
           
                Console.WriteLine(num);
             
                Console.ReadKey();
            
                
        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication9
{
    class Program
    {
        static void Main(string[] args)
        {
            int num = 1;
            while(num < 6)
            {
                Console.WriteLine(num);
                num+=2;
            }
            Console.ReadKey();

            
                
        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication9
{
    class Program
    {
        static void Main(string[] args)
        {
            int num = 1;
            while(num < 6)
            {
                Console.WriteLine(num);
                num++;
            }
            Console.ReadKey();

            
                
        }
    }
}

khaldon asfor
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication9
{
    class Program
    {
        static void Main(string[] args)
        {
            int x, y, z;
            Console.WriteLine("plz enter num bolls");
            x = int.Parse(Console.ReadLine());
            y = x / 20;
            z = x % 20;
            if (z > 0)
            {
                Console.WriteLine(" num bags is" + (y + 1));
            }

            else
            {
                Console.WriteLine(" num bags is" + y);
            }
                Console.ReadKey();
                
            
                
        }
    }
}

الاثنين، 15 أكتوبر 2018

خلدون عصفور 
برنامج يقوم المستخدم به بادخال رقمين ويختار العمليه التي يريدها والبرنامج يقوم بطباعه الجواب


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication8
{
    class Program
    {
        static void Main(string[] args)
        {
            int a,b,c ;
           
            Console.WriteLine ("plz enter num1");
           a=int.Parse(Console.ReadLine());
           Console.WriteLine("plz enter num2");
           b = int.Parse(Console.ReadLine());
            Console.WriteLine("press 1 for addition +");
            Console.WriteLine("press 2 for multipication *");
            Console.WriteLine("press 3 for subtract -");

            c = int.Parse(Console.ReadLine());
            switch (c)
            {
                case 1:
                    Console.WriteLine("the result is" + (a + b));
                    break;
                case 2:
                    Console.WriteLine("the result is" + (a * b));
                    break;
                case 3:
                    Console.WriteLine("the result is" + (a - b));
                    break;
            }
                    Console.ReadKey();
    }
    }
}

السبت، 13 أكتوبر 2018

khaldon asfor
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication7
{
    class Program
    {
        static void Main(string[] args)
        {
            double m, b, c, a , average ;
            Console.WriteLine("plz enter the grade of math");
                m= double.Parse(Console.ReadLine());
            if(m==100)
                Console.WriteLine("math ideal");
            if (m >90 && m<100)
                Console.WriteLine("math exellent");
            if (m > 80 && m < 89)
                Console.WriteLine(" math very good");
            if (m > 70 && m < 79)
                Console.WriteLine("math good");
            if (m > 60 && m < 69)
                Console.WriteLine("math satisfaction");
            if (m >= 50 && m < 59)
                Console.WriteLine("math bad");
            if (m < 50)
                Console.WriteLine("math fail");

            Console.WriteLine("plz enter the grade of biolige");
           b = double.Parse(Console.ReadLine());
           if (b == 100)
               Console.WriteLine("biolige ideal");
           if (b > 90 && b < 100)
               Console.WriteLine("biolige exellent");
           if (b > 80 && b < 89)
               Console.WriteLine("biolige very good");
           if (b > 70 && b < 79)
               Console.WriteLine("biolige good");
           if (b > 60 && b < 69)
               Console.WriteLine("biolige satisfaction");
           if (b >= 50 && b < 59)
               Console.WriteLine("biolige bad");
           if (b < 50)
               Console.WriteLine("biolige fail");

           Console.WriteLine("plz enter the grade of chemistry");
          c= double.Parse(Console.ReadLine());
           if (c == 100)
               Console.WriteLine("chemistry ideal");
           if (c > 90 && c < 100)
               Console.WriteLine("chemistry exellent");
           if (c > 80 && c < 89)
               Console.WriteLine("chemistry very good");
           if (c > 70 && c < 79)
               Console.WriteLine("chemistry good");
           if (c > 60 && c < 69)
               Console.WriteLine("chemistry satisfaction");
           if (c >= 50 && c < 59)
               Console.WriteLine("chemistry bad");
           if (c < 50)
               Console.WriteLine("chemistry fail");
           a = m + b + c;
           average = a / 3;
           Console.WriteLine(" average is" + average);

           if (average == 100)
               Console.WriteLine("average ideal");
           if (average > 90 && average < 100)
               Console.WriteLine("average exellent");
           if (average > 80 && average < 89)
               Console.WriteLine("average very good");
           if (average > 70 && average < 79)
               Console.WriteLine("average good");
           if (average > 60 && average < 70)
               Console.WriteLine("average satisfaction");
           if (average > 50 && average < 59)
               Console.WriteLine("average bad");
           if (average < 50)
               Console.WriteLine("average fail");
           Console.ReadKey();
        }
    }
}

khaldon asfor
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication7
{
    class Program
    {
        static void Main(string[] args)
        {
            double m, b, c, a , average ;
            Console.WriteLine("plz enter the grade of math");
                m= double.Parse(Console.ReadLine());
            if(m==100)
                Console.WriteLine("math ideal");
            if (m >90 && m<100)
                Console.WriteLine("math exellent");
            if (m > 80 && m < 89)
                Console.WriteLine(" math very good");
            if (m > 70 && m < 79)
                Console.WriteLine("math good");
            if (m > 60 && m < 69)
                Console.WriteLine("math satisfaction");
            if (m > 50 && m < 59)
                Console.WriteLine("math bad");
            if (m < 50)
                Console.WriteLine("math fail");

            Console.WriteLine("plz enter the grade of biolige");
           b = double.Parse(Console.ReadLine());
           if (b == 100)
               Console.WriteLine("biolige ideal");
           if (b > 90 && b < 100)
               Console.WriteLine("biolige exellent");
           if (b > 80 && b < 89)
               Console.WriteLine("biolige very good");
           if (b > 70 && b < 79)
               Console.WriteLine("biolige good");
           if (b > 60 && b < 69)
               Console.WriteLine("biolige satisfaction");
           if (b > 50 && b < 59)
               Console.WriteLine("biolige bad");
           if (b < 50)
               Console.WriteLine("biolige fail");

           Console.WriteLine("plz enter the grade of chemistry");
          c= double.Parse(Console.ReadLine());
           if (c == 100)
               Console.WriteLine("chemistry ideal");
           if (c > 90 && c < 100)
               Console.WriteLine("chemistry exellent");
           if (c > 80 && c < 89)
               Console.WriteLine("chemistry very good");
           if (c > 70 && c < 79)
               Console.WriteLine("chemistry good");
           if (c > 60 && c < 69)
               Console.WriteLine("chemistry satisfaction");
           if (c > 50 && c < 59)
               Console.WriteLine("chemistry bad");
           if (c < 50)
               Console.WriteLine("chemistry fail");
           a = m + b + c;
           average = a / 3;
           Console.WriteLine(" average is" + average);

           if (average == 100)
               Console.WriteLine("average ideal");
           if (average > 90 && average < 100)
               Console.WriteLine("average exellent");
           if (average > 80 && average < 89)
               Console.WriteLine("average very good");
           if (average > 70 && average < 79)
               Console.WriteLine("average good");
           if (average > 60 && average < 70)
               Console.WriteLine("average satisfaction");
           if (average > 50 && average < 59)
               Console.WriteLine("average bad");
           if (average < 50)
               Console.WriteLine("average fail");
           Console.ReadKey();
        }
    }
}

الأربعاء، 10 أكتوبر 2018

khaldon asfor
tawfiq mitwalli


using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication6
{
    class Program
    {
        static void Main(string[] args)
        {
            int x = 33;
            if (x==8)
              
                    Console.WriteLine("value of x is 8");
                else if(x==18)
                Console.WriteLine("value of x is 18");
            else if (x==33)
                Console.WriteLine("value of x is 33");
                else
                    Console.WriteLine("no match");
            Console.ReadKey();
        }
    }
}
    
khaldon asfor
tawfiq mitwalli

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication6
{
    class Program
    {
        static void Main(string[] args)
        {
            int age = 17;
            if (age > 14)
                if (age > 18)
                    Console.WriteLine("adult");
                else
                    Console.WriteLine("teenager");
            else
                if (age > 0)
                    Console.WriteLine("child");
                else
                    Console.WriteLine("something wrong");
            Console.ReadKey();
        }
    }
}
    
khaldon asfor
tawfiq mitwalli

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication6
{
    class Program
    {
        static void Main(string[] args)
        {
            int mark = 100;
            if (mark >= 50)
                Console.WriteLine("you passed");
            if (mark == 100)
                Console.WriteLine("perfect");
            else
                Console.WriteLine("you fallied");
            Console.ReadKey();
        }
    }
}
    
khaldon asfor
tawfiq mitwale

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication5
{
    class Program
    {
        static void Main(string[] args)
        {
           int a = 4 ;
            int b = 4 ;
            if (a==b)
            {
                Console.WriteLine("EQUAL");
            }
            Console.ReadKey();
        }
    }
}

1)khaldon asfor
tawfiq mitwalli

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication5
{
    class Program
    {
        static void Main(string[] args)
        {
            int x = 8;
            int y = 3;
            if (x > y)
                Console.WriteLine("is greater then y");
            Console.ReadKey();
        }
    }
}



(2



الاثنين، 8 أكتوبر 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication2
{
    class Program
    {
        static void Main(string[] args)
        {
            int a,c,b;
           
            
                Console.WriteLine("plz enter num ");
                a= int.Parse(Console.ReadLine());

                b = a % 10;
                c = a / 100;
                if (c == b)

              Console.WriteLine("this number is panglaogy ");

                else

                    Console.WriteLine("this number is not panglaogy ");

                Console.ReadKey();
        }
    }
}

الاثنين، 21 مايو 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication36
{
    class Program
    {
        // خلدون عصفور
        // برنامج لحساب قيمة التيار وقيمة الجهد الاول والثاني
        static void Main(string[] args)
        {
            double R1, R2, RT;
            double V, V1, V2;
            double I;
            Console.WriteLine("PLZ enter the V");
            V = double.Parse(Console.ReadLine());
            Console.WriteLine("PLZ enter the R1");
            R1 = double.Parse(Console.ReadLine());
            Console.WriteLine("PLZ enter the R2");
            R2 = double.Parse(Console.ReadLine());
            RT = R1 + R2;
            Console.WriteLine(" the RT IS " + RT+   " OHM");

            I = V / RT;
            Console.WriteLine("the I  IS " + I +   " ABMER");

            V1 = I * R1;
            Console.WriteLine(" the RT IS " + V1+  " VOLT");
            V2 = I * R2;
            Console.WriteLine(" the RT IS " + V2 + " VOLT");
            Console.ReadKey();
        }
    }
}

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
// خلدون عصفور
// برنامج لتحويل من الدولار الى الشيكل
namespace ConsoleApplication35
{
    class Program
    {
        static void Main(string[] args)
        {
            double D;
            double D2;
            double S;

            Console.WriteLine("plz enter the value dolar");
            D2 = double.Parse(Console.ReadLine());

            Console.WriteLine("plz enter the  dolar");
            D = double.Parse(Console.ReadLine());


            S = D * D2;
            Console.WriteLine("your SHEKEL"+ S);
            Console.ReadKey();
        }
    }
}

الخميس، 10 مايو 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApplication68
{

    //عمل الطالب خلدون عصفور
    //مشروع يقوم بحساب الضريبة
    class Program
    {
        static void Main(string[] args)
        {
            string a;
            string f;
            string g;
            double b;
            double y;
            double o;
            double c;
            double d;
            double p;
            double q;
            double m;
            double n;
            double t;
            double x;
            double s;

            Console.WriteLine(" plz enter  item");
            a = Console.ReadLine();
            Console.WriteLine("please price");
            b = double.Parse(Console.ReadLine());

            Console.WriteLine(" plz enter  item 2");
            f = Console.ReadLine();
            Console.WriteLine("please price 2");
            y = double.Parse(Console.ReadLine());

            Console.WriteLine(" plz enter  item 3 ");
            g = Console.ReadLine();
            Console.WriteLine("please price 3 ");
            o = double.Parse(Console.ReadLine());

            c = b * 0.17;
            d = c + b;

            p = y * 0.17;
            q = p + y;

            m = o * 0.17;
            n = o + m;

            t = d + q + n;
            x = c + p + m;
            s = b + y + o; 

            Console.WriteLine(" ******************************************************* ");
            Console.WriteLine("                        tax invaice                      ");
            Console.WriteLine(" ******************************************************* ");
            Console.WriteLine("                         the price                             ");
            Console.WriteLine("       item                                        price           ");
            Console.WriteLine("       {0}                                          {1}  ", a, b);
            Console.WriteLine("       {0}                                          {1}  ", f, y);
            Console.WriteLine("       {0}                                          {1}  ", g, o);
            Console.WriteLine("                                                                    ");
            Console.WriteLine("       total                                       " + s);
            Console.WriteLine("       tax                                         " + x);
            Console.WriteLine("       total                                       " + t);
            Console.WriteLine("*********************************************************");
            Console.WriteLine(" *************thank you......,,,,,,,,,,,,,,,#############");
            Console.ReadKey();

        }
    }
}

الثلاثاء، 8 مايو 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication31
{
    class Program
    {
        // خلدون عصفور
        // برنامج لحساب قيمة التيار
        static void Main(string[] args)
        {
            double V;
            double I;
            double R;
            Console.WriteLine("please enter voltage");
            V= double.Parse(Console.ReadLine());

            Console.WriteLine("please enter resistor");
           R= double.Parse(Console.ReadLine());

           I = V / R;

           Console.WriteLine("The current for V = " +V+ " and R = " +R+ " is " +I+ " ampere");
           Console.ReadKey();
        }
    }
}

الاثنين، 7 مايو 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
// خلدون عصفور
// برنامج لحساب العمر بعد 20 سنة
namespace ConsoleApplication30
{
    class Program
    {
        static void Main(string[] args)
        {
            int Age;
            string yourName;
            int c;
            Console.WriteLine("unter your name?");
            yourName = Console.ReadLine();

            Console.WriteLine("unter your age?");

            Age = int.Parse(Console.ReadLine());
            c = Age + 20;

            Console.WriteLine(" hello, your Name is " + yourName + " and your age is " + Age + " you will be " + c + " after 20 years ");
            Console.ReadKey();
        }
    }
}

الخميس، 3 مايو 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication68
{
    class Program
    {
        static void Main(string[] args) //عمل الطالب خلدون عصفور
        {
            int a; // حساب الباقي 
            int b;
            int c;
          
            
            Console.WriteLine(" enter the first num");
           a = int.Parse(Console.ReadLine());
            Console.WriteLine(" enterthe second num");
            b = int.Parse(Console.ReadLine());
            c = a%b;
            Console.WriteLine( "The rest is" + c);
            Console.ReadKey();
        }
    }
}




using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication68
{
    class Program
    {
        static void Main(string[] args) // عمل الطالب خلدون عصفور
        {
            string name;// برمجة حساب مساحة ومحيط المستطيل
            int Width;
            int Length;
            int a;
            int d;

            Console.WriteLine(" Please enter your name?");
           name = Console.ReadLine();
           Console.WriteLine(" For Rectangle please enter Width");
           Width = int.Parse(Console.ReadLine());
           Console.WriteLine(" For the same Rectangle please enter Length");
           Length = int.Parse(Console.ReadLine());
           a = Width * Length;
           d = Width * 2 + Length * 2;

           Console.WriteLine(" Mr " + name + " The area of the rectangle with length of " + Length + " and width of " + Width + " is " + a);
            Console.WriteLine(" Mr " + name + " The Circumference of the rectanagle is " + d);

            Console.ReadKey();

        }
    }
}





using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication68
{
    class Program
    {
        static void Main(string[] args) // عمل الطالب خلدون عصفور
        {
            string name;// برمجة حساب مساحة ومحيط 
            int r;
            double a;
            double d;
            double b = 3.14;
            Console.WriteLine(" Please enter your name?");
           name = Console.ReadLine();
           Console.WriteLine(" Please enter radius of the circle");
           r= int.Parse(Console.ReadLine());

           a = (r*r)* b ;
           d =  r*2*b;

          Console.WriteLine(" Mr "+ name +" The area of the circle is "+ a + " and the Circumference is " + d);
            Console.ReadKey();

        }
    }
}

الثلاثاء، 1 مايو 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
//program
 //خلدون عصفور
//برنامج لحساب المساحة
namespace ConsoleApplication68
{
    class Program
    {
        static void Main(string[] args)
        {
            int area;
            int L;
            int W;
          
            
            Console.WriteLine("plese enter length");
           L = int.Parse(Console.ReadLine());
            Console.WriteLine("plese enter width");
            W = int.Parse(Console.ReadLine());
            area = L * W;
            Console.WriteLine("the area is " +  area);
            Console.ReadKey();
        }
    }
}

الثلاثاء، 24 أبريل 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication72
{
    class Program
    {
        static void Main(string[] args)
        {
            int Age;
            double Weight;
            string yourName;
            Console.WriteLine("What is ypur name?");
            yourName = Console.ReadLine();

            Console.WriteLine("What is ypur age?");

            Age = int.Parse(Console.ReadLine());

            Console.WriteLine("What is your Weight");
            Weight = double.Parse(Console.ReadLine());

            Console.WriteLine("your Name is {0} and your age is {1} and your weight is {2}", yourName, Age, Weight);
            Console.ReadKey();

        }
    }
}

الاثنين، 23 أبريل 2018

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication22
{
    class Program
    {
        static void Main(string[] args)
        {
            int x = 42;
            double pi = 3.14;
            char y = 'z';
            bool isonline = true;
            string firstName ="david";
            Console.WriteLine (x);
            Console.WriteLine (pi);
            Console.WriteLine (y);
            Console.WriteLine(isonline);
            Console.WriteLine(firstName);
            Console.ReadKey();


        }
    }
}