الفريق العربي للبرمجةأرشيف المنتديات · 2000 – 2023
نسخة أرشيفية للقراءة فقط — التسجيل والمشاركة مغلقان، والمحتوى محفوظ كما كان.

مساعدة في الحل

مغلق
بدأه alr7al في 6 يوليو 2003 · 2 رد · 917 مشاهدة · في الأسئلة المجابة
مشاركة: واتساب X فيسبوك تيليجرام
#1 صاحب الموضوع

السلام عليكم

1. Distinguish between the terms "function templates"and "function-template specialization"

2. why might you choose to use a function templates instead of macro

3. write a statement for each of the following :

a) print integer 40000 left-justified in a 15-digit field.

B) read a string into character array variable state .

c) print 200 with and without a sign.

d) print the decimal value 100 in hexadecimql from preceded by 0x.

e) read characters into array chararray until the char 'p' is encounyered ,up to a

limit of 10 char (including the terminating null char) .extract the delimiter

from the input stream and discard it.

f) print 1.234 in a 9-digit field with preceding zeros.

g) read a string of the form "characters" from the standard input .

store the string in a maximum of 50 char(including the terminating null char)

#2

إذا كنت تستخدم سي بلس بلس:

#include <iostream>

#include <iomanip>

using namespace std;

void main ()

{

char x[10];

int i=0;



cout <<setw(15)<<40000<<endl;

cout<<200<<endl;



cin>>x[0];

while (x!='p' && i<10)

{

i++;

cin>>x;

}



}
#3

شكرا لك اخي الكريم

هذا الموضوع مغلق.

مواضيع مشابهة