اذهب إلى المحتوى

AM0

الأعضاء
  • المساهمات

    22
  • تاريخ الانضمام

  • تاريخ آخر زيارة

آخر الزوار

لوحة آخر الزوار معطلة ولن تظهر للأعضاء

إنجازات AM0

عضو مساهم

عضو مساهم (2/3)

4

السمعة بالموقع

  1. عندي دالة ال newStepper ف ابغا انشئ منها اله حاسبه ممكن تساعدوني:(؟
  2. انا انشأت لعبه في هذا البرنامج وانتهيت لاكن اريد ان اضيف عداد يحسب كم مره نقر المستخدم على اللعبه واذا تعدى ال 20 مثلا يطبع رساله له انه فاز وهكذا ارجووو المساعده
  3. اذا العدد المدخل فردي او موجب يطبيع انه فردي او موجب
  4. شكرا جزاك الله الف خير الله يعطيك العافيه👍🏻
  5. اكوادي هذي كنت ابغا احط قائمه فيها العب من جديد او مو شرط قائمه بس ابغا اضغط ويخلي الللعبه تنعاد يعني ابغا شيفره تعيد لي اللعبه هذي الاكواد public partial class Form1 : Form { int count = 0; public Form1() { InitializeComponent(); } private void winner() { if ((button1.Text == button2.Text) && (button1.Text == button3.Text) && button1.Text!="") { if (count % 2 == 0) { MessageBox.Show("Player 1 is the winner"); Application.Exit(); } else { MessageBox.Show("Player 2 is the winner"); Application.Exit(); } } if ((button4.Text == button5.Text) && (button4.Text == button6.Text) && button4.Text != "") { if (count % 2 == 0) { MessageBox.Show("Player 1 is the winner"); Application.Exit(); } else { MessageBox.Show("Player 2 is the winner"); Application.Exit(); } } if ((button7.Text == button8.Text) && (button8.Text == button9.Text) && button7.Text != "") { if (count % 2 == 0) { MessageBox.Show("Player 1 is the winner"); Application.Exit(); } else { MessageBox.Show("Player 2 is the winner"); Application.Exit(); } } if ((button1.Text == button4.Text) && (button4.Text == button7.Text) && button1.Text != "") { if (count % 2 == 0) { MessageBox.Show("Player 1 is the winner"); Application.Exit(); } else { MessageBox.Show("Player 2 is the winner"); Application.Exit(); } } if ((button2.Text == button5.Text) && (button2.Text == button8.Text) && button2.Text != "") { if (count % 2 == 0) { MessageBox.Show("Player 1 is the winner"); Application.Exit(); } else { MessageBox.Show("Player 2 is the winner"); Application.Exit(); } } if ((button3.Text == button6.Text) && (button3.Text == button9.Text) && button3.Text != "") { if (count % 2 == 0) { MessageBox.Show("Player 1 is the winner"); Application.Exit(); } else { MessageBox.Show("Player 2 is the winner"); Application.Exit(); } } if ((button1.Text == button5.Text) && (button1.Text == button9.Text) && button1.Text != "") { if (count % 2 == 0) { MessageBox.Show("Player 1 is the winner"); Application.Exit(); } else { MessageBox.Show("Player 2 is the winner"); Application.Exit(); } } if ((button3.Text == button5.Text) && (button3.Text == button7.Text) && button3.Text != "") { if (count % 2 == 0) { MessageBox.Show("Player 1 is the winner"); Application.Exit(); } else { MessageBox.Show("Player 2 is the winner"); Application.Exit(); } } } private void button1_Click(object sender, EventArgs e) { if (count % 2==0) { button1.Text = "O"; button1.Enabled = false; winner(); count++; } else { button1.Text = "X"; button1.Enabled = false; winner(); count++; } } private void button2_Click(object sender, EventArgs e) { if (count % 2 == 0) { button2.Text = "O"; button2.Enabled = false; winner(); count++; } else { button2.Text = "X"; button2.Enabled = false; winner(); count++; } } private void button3_Click(object sender, EventArgs e) { if (count % 2 == 0) { button3.Text = "O"; button3.Enabled = false; winner(); count++; } else { button3.Text = "X"; button3.Enabled = false; winner(); count++; } } private void button4_Click(object sender, EventArgs e) { if (count % 2 == 0) { button4.Text = "O"; button4.Enabled = false; winner(); count++; } else { button4.Text = "X"; button4.Enabled = false; winner(); count++; } } private void button5_Click(object sender, EventArgs e) { if (count % 2 == 0) { button5.Text = "O"; button5.Enabled = false; winner(); count++; } else { button5.Text = "X"; button5.Enabled = false; winner(); count++; } } private void button6_Click(object sender, EventArgs e) { if (count % 2 == 0) { button6.Text = "O"; button6.Enabled = false; winner(); count++; } else { button6.Text = "X"; button6.Enabled = false; winner(); count++; } } private void button7_Click(object sender, EventArgs e) { if (count % 2 == 0) { button7.Text = "O"; button7.Enabled = false; winner(); count++; } else { button7.Text = "X"; button7.Enabled = false; winner(); count++; } } private void button8_Click(object sender, EventArgs e) { if (count % 2 == 0) { button8.Text = "O"; button8.Enabled = false; winner(); count++; } else { button8.Text = "X"; button8.Enabled = false; winner(); count++; } } private void button9_Click(object sender, EventArgs e) { if (count % 2 == 0) { button9.Text = "O"; button9.Enabled = false; winner(); count++; } else { button9.Text = "X"; button9.Enabled = false; winner(); count++; } } }
  6. انا عملت لعبة Tic Tac toa في شرط الاف ايلس ف حطيت قائمه فيها العب من جديد بس كيف استخدمها في الكود غير Clear لان بيطلع فيها ايرور؟ اررررجو الاجابه
  7. ابغا من نفس اللعبه اقدري اسوي اعاده واعيد اللعب مو كل مره اسوي ستارت
  8. السلام عليكم طيب لو ابي المستخدم هو يدخل الاسم وينطبع العكس علطول ؟
  9. شكرا جزيلا لاكن لو بستخدمها في طريقة ال for بدل ال while هل ينفع ؟
  10. اريد ان انشئ دالة تسمى Invert تستقبل جملة نصية تطبع الكلمة عكس مثلا hello تصبح olleh جربتها في مصفوفه وضبط معاي لاكن في الدالة كيف ؟
  11. السلام عليكم ورحمة الله وبركاته كيف انشئي برنامج يحتوي على دالة تسمى Invert بحيث تستقبل هذه الدالة جملة نصية وتقوم بطباعة احرف النص معكوسة
  12. برنامج يطلب من المستخدم ادخال سنة ميلاده ثم يحسب عمره بطرح سنة ميلاده من السنه الحاليه
  13. كيف انشئ برنامج يستخدم دالة تسمى CountSpaces()تستقبل جملة نصية من المستخدم وتطبع عدد المسافات الفارغة " " في هذه الجملة ؟ يعني زي كذا
  14. حطيته بالبرنامج ويطلع Error عند Console.WriteLine(result)؛ اللي فوق حطيتها ف الداله والطباعه ذي حطيتها ف ال main وجربت استدعي وكل شي بس مو عارفه ليه عن result يطلع خطأ
×
×
  • أضف...