نصائح و استشارات برمجية
1.45K subscribers
546 photos
10 videos
83 files
398 links
• نصائح واستشارات برمجية متعلقة باسئلة تم طرحها

• لطرح استفسار او سؤال: @m4md24
Download Telegram
This media is not supported in your browser
VIEW IN TELEGRAM
ابي برنامج جافا اكتب فيه أكواد وزين بالماك
This media is not supported in your browser
VIEW IN TELEGRAM
نصائح و استشارات برمجية
Photo
#include <iostream>

using namespace std;

int countEvenNumbersBefore(int num) {
int count = 0;
for (int i = 0; i <= num; ++i) {
if (i % 2 == 0) count++;
}
return count;
}

int main() {
int userInput;
cout << "Please enter a number: ";
cin >> userInput;

int result = countEvenNumbersBefore(userInput);
cout << "Number of even numbers before " << userInput << ": " << result << endl;

return 0;
}
This media is not supported in your browser
VIEW IN TELEGRAM
وش الفرونت اند والباك اند ؟
نصائح و استشارات برمجية
وش الفرونت اند والباك اند ؟
• الـ Front-End بشكل عام للمجالات مثلاً:
- التصاميم اللي بالاكواد في المشاريع

• الـ Back-End بشكل عام للمجالات، مثلاً
- لما اجي اضغط على زر معين يطلعلي و ليكن نتيجة لعملية ضرب معينة، نفهم من هذا الموضوع انه المسئول عن مجال زي دا هو اللي بيعمل اوامر الكواليس بالاكواد.
This media is not supported in your browser
VIEW IN TELEGRAM
#include <iostream>
using namespace std;

enum enweekday { sun = 1, mon = 2, tue = 3, wed = 4, thu = 5, fri = 6, sat = 7 };

void showweekday()
{
cout << "*************************" << endl;
cout << "* week day meue *" << endl;
cout << "*************************" << endl;
cout << "(1) sunday." << endl;
cout << "(2) monday." << endl;
cout << "(3) tuesday." << endl;
cout << "(4) wednesday." << endl;
cout << "(5) thursday." << endl;
cout << "(6) friday." << endl;
cout << "(7) saturday." << endl;
cout << "*************************" << endl;
cout << "please enter the number of day ?" << endl;
}

enweekday redweekday()
{
enweekday weekday;
int wd;
cin >> wd;
return (enweekday)wd;
}

string getweekdayname(enweekday weekday)
{
switch (weekday)
{
case sun:
cout << "sunday" << endl;
break;
case mon:
cout << "monday" << endl;
break;
case tue:
cout << "tuesday" << endl;
break;
case wed:
cout << "wednesday" << endl;
break;
case thu:
cout << "thusday" << endl;
break;
case fri:
cout << "friday" << endl;
break;
case sat:
cout << "saterday" << endl;
break;
default:
cout << "wrong day" << endl;
break;
}




}

int main()
{
showweekday();

cout << "today is " << getweekdayname(redweekday()) << endl;

return 0;
}




وين الايرور ؟؟؟
نصائح و استشارات برمجية
#include <iostream> using namespace std; enum enweekday { sun = 1, mon = 2, tue = 3, wed = 4, thu = 5, fri = 6, sat = 7 }; void showweekday() { cout << "*************************" << endl; cout << "* week day meue *" << endl; cout << "****…
دا التصحيح ↓

#include <iostream>
using namespace std;

enum enweekday { sun = 1, mon = 2, tue = 3, wed = 4, thu = 5, fri = 6, sat = 7 };

void showweekday()
{
cout << "*************************" << endl;
cout << "* week day menu *" << endl;
cout << "*************************" << endl;
cout << "(1) sunday." << endl;
cout << "(2) monday." << endl;
cout << "(3) tuesday." << endl;
cout << "(4) wednesday." << endl;
cout << "(5) thursday." << endl;
cout << "(6) friday." << endl;
cout << "(7) saturday." << endl;
cout << "*************************" << endl;
cout << "please enter the number of day ?" << endl;
}

enweekday readweekday()
{
int wd;
cin >> wd;
return static_cast<enweekday>(wd);
}

string getweekdayname(enweekday weekday)
{
switch (weekday)
{
case sun:
return "sunday";
case mon:
return "monday";
case tue:
return "tuesday";
case wed:
return "wednesday";
case thu:
return "thusday";
case fri:
return "friday";
case sat:
return "saturday";
default:
return "wrong day";
}
}

int main()
{
showweekday();

cout << "today is " << getweekdayname(readweekday()) << endl;

return 0;
}
This media is not supported in your browser
VIEW IN TELEGRAM
الكود دا صح؟

x=int(input("Enter 1st number:"))
y=int(input("Enter 2nd number:"))
z=float(input("Enter 3rd number:"))
n1=x+y+z
n2=n1/3
n3=x*y*z
n4=x-y-z
n5=x%y%z
print n1
print n2
print n3
print n4
print n4
نصائح و استشارات برمجية
الكود دا صح؟ x=int(input("Enter 1st number:")) y=int(input("Enter 2nd number:")) z=float(input("Enter 3rd number:")) n1=x+y+z n2=n1/3 n3=x*y*z n4=x-y-z n5=x%y%z print n1 print n2 print n3 print n4 print n4
• غلطانه في امر الطباعة، دا التصحيح ↓
x = int(input("Enter 1st number:"))
y = int(input("Enter 2nd number:"))
z = float(input("Enter 3rd number:"))
n1 = x + y + z
n2 = n1 / 3
n3 = x * y * z
n4 = x - y - z
n5 = x % y % z
print(n1)
print(n2)
print(n3)
print(n4)
print(n5)
This media is not supported in your browser
VIEW IN TELEGRAM
لتعلم سي شارب
خصوصا موضوع stack