Our Services

Get 15% Discount on your First Order

[rank_math_breadcrumb]

CS 231 ASS 1

Description

SEE

College of Computing and Informatics

Assignment #1
Deadline: Monday 29/09/2025 @ 23:59
[Total Mark for this Assignment is 8]
Student Details:
Name: ###

ID: ###

CRN: ###
Instructions:

• You must submit two separate copies (one Word file and one PDF file) using the Assignment Template on
Blackboard via the allocated folder. These files must not be in compressed format.

• It is your responsibility to check and make sure that you have uploaded both the correct files.
• Zero mark will be given if you try to bypass the SafeAssign (e.g. misspell words, remove spaces between
words, hide characters, use different character sets, convert text into image or languages other than English
or any kind of manipulation).

• Email submission will not be accepted.
• You are advised to make your work clear and well-presented. This includes filling your information on the cover
page.

• You must use this template, failing which will result in zero mark.
• You MUST show all your work, and text must not be converted into an image, unless specified otherwise by
the question.

• Late submission will result in ZERO mark.
• The work should be your own, copying from students or other resources will result in ZERO mark.
• Use Times New Roman font for all your answers.

Restricted – ‫مقيد‬

Question One

Pg. 01

Learning
Outcome(s):

Question One

Explain the basic

In Java programming, there are three main categories of errors that programmers
commonly face.

principles of
programming,
concept of
language, and
universal
constructs of
programming
languages

Restricted – ‫مقيد‬

1. Identify and briefly describe each category.
2. Provide one example (code snippet or scenario) for each.
3. Explain how a programmer can detect and correct these errors.

2 Marks

Question Two

Pg. 02
Learning
Outcome(s):
Explain the basic
principles of
programming,
concept of
language, and
universal
constructs of
programming
languages

Restricted – ‫مقيد‬

Question Two

2 Marks

Write a program that asks the user for their weight (double) and height (double), then
calculates and prints their Body Mass Index(BMI).
BMI = weight / (height * height)

Question Three

Pg. 03
Learning
Outcome(s):
Develop a
program based on
specification
using
programming
language
elements
including syntax,
data types,
conditional
statement, control
structures,
procedures,
arrays, objects
and classes.

Restricted – ‫مقيد‬

Question Three

2 Marks

Write a Java program that declares and initializes variables of all the primitive types:

int, double, char, and Boolean.

The program should:
1. Print the variables’ values on the screen.
2. Add the keyword final to the int variable and try to reassign it (observe the
error).
3. Reassign new values to the remaining variables (double, char, and Boolean) and
print the results again.

Question Four

Pg. 04
Learning
Outcome(s):
Develop a
program based on
specification
using

Question Four
Write a Java program that asks the user to enter a number.
If the number is positive, print:
“The number is positive.”
If the number is negative, print:
“The number is negative.”

programming

If the number is zero, print:
“The number is zero.”

language

Sample Output:

elements
including syntax,
data types,

OR:

conditional
statement, control
structures,
procedures,
arrays, objects
and classes.

Restricted – ‫مقيد‬

OR:

2 Marks

Purchase answer to see full
attachment

Share This Post

Email
WhatsApp
Facebook
Twitter
LinkedIn
Pinterest
Reddit

Order a Similar Paper and get 15% Discount on your First Order

Related Questions

HCM 515 model 4 master

Description For this discussion, we are examining public and private healthcare facilities. Locate two different facilities in the Kingdom of Saudi Arabia – one private and one public. Examine the difference and similarities you see in the different facilities. Explain how the law impacts how these two facilities operate? Embed

Management Question

Description ‫المملكة العربية السعودية‬ ‫وزارة التعليم‬ ‫الجامعة السعودية اإللكترونية‬ Kingdom of Saudi Arabia Ministry of Education Saudi Electronic University College of Administrative and Financial Sciences Assignment 1 Entrepreneurship and small business (MGT 402) Due Date: 04/10/2025 @ 23:59 Course Name: Entrepreneurship and small business Course Code: MGT402 Student’s Name: Semester:

Project ECOM201

Description NO COPING , Only one part ،، The country is Spain Saudi Electronic University College of Administrative and Financial Sciences E-commerce Department Group Project Group Students Names: Cover Page Group IDs: Course Title: Introduction to EManagement Course Code: ECOM 201 Academic Year/ Semester: 2025/20261st Term Instructor Name: CRN: Student

IT 244 DIS 1

Description SEE IT244-Introduction to Database Discussion Board Purpose In this discussion board, you will post your answer to the question. You will also read and respond to other classmates’ postings. This is an excellent way for you to interact with your colleagues and to share your thoughts about the question

IT 245 DIS 1

Description SEE IT245 Description of Discussion Board Purpose The purpose of discussion board activity is familiarized student with the significance of Data structure Action Items Access the discussion forum for this assignment by clicking on the discussion forum title. Click on “Create Thread.” Enter a title for your response in

CS 231 DIS 2

Description SEE College of Computing and Informatics Discussion Board Deadline: Day 28/09/2025 @ 23:58 [Total Mark is 4] Pg. 01 Purpose: In this discussion board, you will post your answer to the given question. You will also read and respond to other classmates’ postings. This is a particular way for

CS 230 DIS 1

Description SEE College of Computing and Informatics CS230 – Object-oriented Programming Discussion Board Topic of Discussion 1. Post your answer to the Questions below: Programs often store data in variables and then make decisions with them. Imagine you are creating a simple game or app (for example: a quiz, a

CS 230 DIS 1

Description SEE College of Computing and Informatics CS230 – Object-oriented Programming Discussion Board Topic of Discussion 1. Post your answer to the Questions below: Programs often store data in variables and then make decisions with them. Imagine you are creating a simple game or app (for example: a quiz, a

HCM 520 CT 4

Description Leadership Styles During a Crisis (110 points) Crisis situations require effective leadership to direct a unified quality healthcare response. Using the Saudi Digital Library, locate and read three scholarly research articles on the role of leadership in managing quality and safety initiatives during crisis situations in Saudi Arabia. Based

discussion 3 FIN500

Description Financial Analysis Financial analysis can be defined as the process of assessing the financial condition of a firm. It can be very useful in understanding the financial position of a company. There are varieties of ratios that can be used for this purpose but each has it benefits and

Accounting Question

Description Students must mention question number clearly in their answer. Late submission will NOT be accepted. Avoid plagiarism, the work should be in your own words, copying from students or other resources without proper referencing will result in ZERO marks. No exceptions. All answers must be typed using Times New

MGT521 M4-Discussion Forum: Writing a Vision for Change Statement

Description I need help completing a discussion board post for my Management course (Managing Dynamic Environment). Below are the exact requirements provided by my instructor: Description: Vision plays a central role in change management. You must have an idea in order to exert the resources to achieve it, and this

MGT530 M4-Discussion Forum: Forecasting Applications

Description I need help completing a discussion board post for my Management course (Operation Management). Below are the exact requirements provided by my instructor: Description: In his module, you will focus on the importance of forecasting as it relates to operations management. This will include the meaningful units in forecasting,

phc 312 ass 1

Description see PHC 312 Group Assignment Paper College of Health Sciences ASSIGNMENT COVER SHEET Course name: Health Communications Course code: PHC312 CRN: XXX Assignment title or task: Students enrolled in PHC 312 in first term 2025 will be divided into groups (3-5 students per group). The first section will be

phc 312 ass 1

Description see PHC 312 Group Assignment Paper College of Health Sciences ASSIGNMENT COVER SHEET Course name: Health Communications Course code: PHC312 CRN: XXX Assignment title or task: Students enrolled in PHC 312 in first term 2025 will be divided into groups (3-5 students per group). The first section will be

discussion ECN500

Description Trade barriers Trade barriers often aim to protect domestic industries but can lead to inefficiencies and higher consumer prices. Discuss the balance between protecting local economies and promoting global trade efficiency. Should governments prioritize free trade or protectionism?” Saudi Arabia has implemented various trade policies in its Vision 2030

MGT – 324

Description Make sure to avoid plagiarism as much as possible . -Use font Times New Roman , 12 font sizes. -Use 1.5 line spacing with adjust to all paragraphs ( alignment ) . -Use the footer function to insert page number. -Ensure that you follow the APA style in your

Managment of information

Description ✓ Use font Times New Roman, 12 font sizes ✓ Use 1.5 line spacing with adjust to all paragraphs (alignment). ✓ Use the footer function to insert page number. ✓ Ensure that you follow the APA style in your project and references. ✓ The minimum number of required references