Lab 13 Work ics 101 الله يوفقكم

الموضوع في 'علوم الحاسب الآلي' بواسطة كمبيوتك, بتاريخ ‏5 يونيو 2010.

  1. كمبيوتك

    انضم:
    ‏16 أغسطس 2008
    المشاركات:
    16
    التقييمات:
    +0 / 0 / -0
    السلام عليكم ورحمة الله وبركاته كيف حال الشباب مع الفينلات

    يا شباب بس حبيت لو احد حل Lab 13 Work ياليت لو يرفع الحل :good: الله يعطيه العافية ويفوفقه

    علما ان Lab 13 Work اي واحد (خياري) من الامثلة 3 اللي تحت


    Exercise 1



    Two matrices A and B of maximum size 5x5 have the same number of rows and columns. Write a program that reads the number of rows and the number of columns, it then reads the two matrices row-wise and it calculates the matrix C which is A + B. Print the matrix C.



    Use the following data:

    2 3



    A

    3 1 4
    7 6 2




    B

    6 4 2
    1 3 5




    C

    9 5 6
    8 9 7








    Exercise 2



    A car selling company sells three car models in each of its four shops. The current car stock for the company is:


    SHOP1
    SHOP2
    SHOP3
    SHOP4

    MODEL1
    5
    7
    3
    0

    MODEL2
    2
    6
    4
    8

    MODEL3
    3
    12
    10
    5




    Write a program which reads the stock data into a two-dimensional array. The program then prints tables of the total number of cars in each shop.



    The output should be in the form:

    SHOP# NUMBER OF CARS

    1 10

    2 25

    3 17

    4 13



    Exercise 3



    Write a program which reads the number of rows and the number of columns of a two-dimensional INTEGER array of maximum size 5 X 5 it then reads an integer value N. If N is not a valid row number the program prints the error message INVALID ROW NUMBER otherwise it reads the array row-wise and it passes it and N to an integer function PRODCT which returns the product of the elements of row N. The program then prints this product.

    Use the following data:

    3 4

    2

    2 4 6 8

    3 3 4 5

    1 2 3 4



    Your output should be:

    PRODUCT OF ROW# 2 = 180
     
جاري تحميل الصفحة...
مواضيع شبيهة - Lab ics 101 الله يوفقكم
  1. كمبيوتك
    الردود:
    2
    المشاهدات:
    569
  2. احمد العنزي*
    الردود:
    12
    المشاهدات:
    786
  3. الأرهابي
    الردود:
    2
    المشاهدات:
    1,129
  4. Ahm2d__
    الردود:
    1
    المشاهدات:
    875
  5. أبوجاسر
    الردود:
    0
    المشاهدات:
    1,483
  6. A_M_J
    الردود:
    0
    المشاهدات:
    1,371
  7. majed111
    الردود:
    2
    المشاهدات:
    2,240
  8. mirdef_4500
    الردود:
    1
    المشاهدات:
    1,555
  9. خالد 2015
    الردود:
    2
    المشاهدات:
    2,430
  10. Abd ElRazzaq
    الردود:
    0
    المشاهدات:
    828

مشاركة هذه الصفحة