0% found this document useful (0 votes)
14 views

Spring 2024 - CS508 - 1

The document provides instructions for an assignment on programming languages for a course. It outlines three questions regarding comparing code snippets in C and Ada, filling out a table with appropriate languages for different statements, and explaining how the if statement differs between C and Ada.

Uploaded by

layropubg5
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views

Spring 2024 - CS508 - 1

The document provides instructions for an assignment on programming languages for a course. It outlines three questions regarding comparing code snippets in C and Ada, filling out a table with appropriate languages for different statements, and explaining how the if statement differs between C and Ada.

Uploaded by

layropubg5
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

CS508 – Modern Programming Languages

Total Marks: 15
Assignment No. 01
Semester: Spring 2024 Due Date: 29-April-2024

Instructions:

Please read the following instructions carefully before submitting assignment:

You need to use MS word document to prepare and submit the assignment on VU-LMS.

It should be clear that your assignment will not get any credit if:

 The assignment is submitted after due date.


 The assignment is not in the required format (doc or docx)
 The submitted assignment does not open or file is corrupt.
 Assignment is copied (partial or full) from any source (websites, forums, students,
etc)

Objectives:

The objective of this assignment is to enhance the learning capabilities of the students about:

 Introduction to Programming Language


 Keywords
 If Statement

If you have any confusion, you can send your query at [email protected]

1
CS508 – Modern Programming Languages
Total Marks: 15
Assignment No. 01
Semester: Spring 2024 Due Date: 29-April-2024

Question No. 1: Marks: 5


Compare the following code snippets in C and Ada. How do the operators and data types differ between the two
languages?

C Code Snippet:

Ada Code Snippet:

2
CS508 – Modern Programming Languages
Total Marks: 15
Assignment No. 01
Semester: Spring 2024 Due Date: 29-April-2024

Question No. 2: Marks 5

You are required to fill out the following table correctly by writing the name of appropriate language in front
of each row.

Note: Please don’t create a new table; use the following table only.

Statement Appropriate
Language

The programming language was designed primarily for hardware description.

The programming language known for its powerful operators for string pattern
matching but suffered from poor readability and maintainability.

The first programming language introduced the concept of a class, which served as
the basis for data abstraction.

The programming language was primarily designed for teaching structured


programming and gained popularity for its simplicity and size.

The programming language designed for systems programming at Bell Labs, which
evolved from B and was influenced by ALGOL 68.

Question No. 3: Marks: 5

Suppose you as a programming student going to learn how to use the “if statement” in 2 different
programming languages like C and Ada.

Let’s first consider the following C “if statement”.

if (some condition)
//

Now consider the “if statement” in Ada programming language.

3
CS508 – Modern Programming Languages
Total Marks: 15
Assignment No. 01
Semester: Spring 2024 Due Date: 29-April-2024

if (some condition) then


-- do this
end if
-- now do this

Now by keeping an eye on the above codes, answer the following question:

How does the "if statement" differ between C and Ada? Justify your answer with valid
reason.

You might also like