Week 1: Programming Assignment 1
Complete the code segment to find the perimeter and area of a circle given a value of radius.
You should use Math.PI constant in your program. If radius is zero or less than zero then print " please enter non zero positive number ".
Public Test Cases | Input | Expected Output | Actual Output | Status |
---|---|---|---|---|
Test Case 1 | 2.0 | 12.566370614359172\n
12.566370614359172 | 12.566370614359172\n
12.566370614359172 | Passed |
Private Test cases used for Evaluation | Status |
Test Case 1 | Passed |
Week 1 : Programming Assignment 2
Due on 2023-08-10, 23:59 ISTComplete the code segment to find the largest among three numbers x,y, and z. You should use if-then-else construct in Java.
Public Test Cases Input Expected Output Actual Output Status Test Case 1 -4 -2 -5
-2
-2
Passed
Complete the code segment to find the largest among three numbers x,y, and z. You should use if-then-else construct in Java.
Public Test Cases | Input | Expected Output | Actual Output | Status |
---|---|---|---|---|
Test Case 1 | -4 -2 -5 | -2 | -2 | Passed |
Private Test cases used for Evaluation | Status |
Test Case 1 | Passed |
Test Case 2 | Passed |
Week 1 : Programming Assignment 3
Consider First n even numbers starting from zero(0).Complete the code segment to calculate sum of all the numbers divisible by 3 from 0 to n. Print the sum.
Example:
Input: n = 5
-------
0 2 4 6 8
Even number divisible by 3:0 6
sum:6
Public Test Cases | Input | Expected Output | Actual Output | Status |
---|---|---|---|---|
Test Case 1 | 1 | 0 | 0 | Passed |
Private Test cases used for Evaluation | Status |
Test Case 1 | Passed |
Test Case 2 | Passed |
Week 1 : Programming Assignment 4
Complete the code segment to check whether the number is an Armstrong number or not.
Armstrong Number:
A positive number is called an Armstrong number if it is equal to the sum of cubes of its digits for example 153 = 13+53+33, 370, 371, 407, etc.
Public Test Cases | Input | Expected Output | Actual Output | Status |
---|---|---|---|---|
Test Case 1 | 203 | 0 | 0 | Passed |
Private Test cases used for Evaluation | Status |
Test Case 1 | Passed |
Test Case 2 | Passed |
Week 1 : Programming Assignment 5
Complete the code segment to help Ragav , find the highest mark and average mark secured by him in "s" number of subjects.
Public Test Cases | Input | Expected Output | Actual Output | Status |
---|---|---|---|---|
Test Case 1 | 5
20 50 60 40 70 | 70\n
48.0 | 70\n
48.0 | Passed |
Private Test cases used for Evaluation | Status |
Test Case 1 | Passed |
Test Case 2 | Passed |
No comments