Вы находитесь на странице: 1из 1

# An-Najah National University Department of Computer Engineering Computer Programming 66111 HW ! HW" #\$%&!

#\$%6 :'1( Write a complete C/C++ program to do the following Define static array called A of size 5 of type double, read all elements from eyboard then a! Compute the product of all elements that found in e"en indices #\$,%,&'!( b! )ort the array in ascending order *small +large, then print the largest "alue in the array! ' ( Define two dynamic arrays called - and C of size .\$ of type character, read all :elements from eyboard then compute /he count of occurrence of mathematical operator *0+1,1+0,1/1,121, in array 3ill a new dynamically allocated array called D from only the small letters in both arrays - and C ! :'"( Write a complete C/C++ program to do the following .+ Define an ) 4atri5 of dimension &5& of type integer and read all elements from eyboard *olumn-*olumn+ %+ 6rint only the prime numbers that found on row that has the smallest "alue! ',( Write a function that ta es an integer m as a parameter then return the following *sum! *call the function from main
Y =m Y =%

8 *%Y + 9\$ , 7)um

!'&: Write function that ta e a string - an. a character C as parameters :our function should compute and return how many character in the string ) is +larger than character C '6( Write a complete C/C++ program to do the following: .+ ;ead 5\$ name of ma5imum size 8. and store them in a 4atri5 called <! %+ Count number of names that end with character =y= 8+ )ort the names in 4atri5 in descending order *>arge to )mall, &+ Compute the longest name in this matri5 and its location 5+ ;eplace each name e?ual @AliA with @)amiA Dea. \$ine for at 1/0/ 111 2oo. \$u*3