أوجد الاخطاء في البرنامج التالي، مع تحديد رقم السطر، حدد الخطأ، وقم بتصحيحه
-
2022-10-19
- | adnandsibai
- | م252
include<iostream>;
int main()
int x=9
double y='a';
cout>>"please, enter the number to multiply it with 9">>num1>>endl;
cin<<num1;
cout>> num1>> "* 9 =">>num1*y>>endl;
}
الأجوبة
ابحث عن مسائل برمجة سي بلس بلس | C++ programming بالانجليزي
سطر رقم 1
التصحيح:
#include<iostream>
سطر رقم 2
التصحيح:
int main(){
سطر رقم 3
التصحيح
int x = 9;
سطر رقم 5
التصحيح:
std::cout << "please, enter the number to multiply it with 9" << y << std::endl;
سطر رقم 6
التصحيح
std::cin >> y;
سطر رقم 7
التصحيح:
std::cout << y << "* 9 =" << x*y << std::endl;
الكود كامل
#include<iostream>
int main(){
int x = 9;
double y = 'a';
std::cout << "please, enter the number to multiply it with 9" << y << std::endl;
std::cin >> y;
std::cout << y << "* 9 =" << x*y << std::endl;
}
-
2022-11-09
- | Programmer
- | إبلاغ عن إساءة