Rust (iron(III) oxide) is formed by the reaction
of oxygen with iron.
4Fe(s) + 302 (g)
> 2Fe2O3 (s)
a. Calculate the mass of oxygen required to
react with 10.0 g of iron.
Unique Matrix
You are given a N*N matrix. write a program to check if the matrix is unique or not. A unique Matrix is a matrix if every row and column of the matrix contains all the integers from 1 to N
Input
The first line contains an integer N.
The next N lines contains N space separated values of the matrix.
Output:
The output contains a single line and should be True if the matrix is unique matrix and False otherwise.
Sample input:
4
1 2 3 4
2 3 4 1
3 4 1 2
4 1 2 3
Sample output:
True
Sample Input2
4
1 2 3 3
2 3 4 1
3 4 1 2
4 1 2 3
Sample Output
False
The goal of this coding exam is to quickly get you off the ground with the array method every ()
There is a selecting going on for civil service centre candidates have to participate in a number of events and the candid pose quotes more than 75 points in every event will be selected
Given candidateList as input it contains objects with name of the candidate and array consisting of poet attitude in each given by the candidate
Write a JS program to,
. Filter the candidates who have score more than 75 points in every event.
. Log the consisting of names of the selected candidates in the console
Input:
. The input will be a single line containing an array of objects candidatesList
Constraints
.keys object should be given in quotes
Sample input
[{'name:'blake,'points':[76,98,88,84]},{'name':'james','points':[098,12,33]},]
Output
[Blake]
Minimal Absolute Difference
There are N pyramids in a line.You are given their heights as a list of integers.Write a program to find the minimum absolute difference between the heights of any two different pyramids.
Input
The input is a single line containing space-separated integers.
Output
The output should be a single line containing the minimum absolute difference of any two different pyramid heights.
Explaanation
Given Pyramid heights are 7 1 5.
The absolute difference between the heights of any two different pyramids are
Matrix Triangle Sum
You are given a square matrix of size NxN, write a program to print the sum of upper and lower triangular elements.
Upper triangle consists of elements on the anti-diagonal and above it. The lower triangle consists of elements on the anti-diagonal and below it.
Explanation:
In the example,if the given matrix is
1 2 3
4 5 6
7 8 9
The upper triangle consists of elements on the anti-diagonal and above on it.
1 2 3
4 5
7
The sum of upper triangle elements is (1+2+3+4+5+7) equal to 22.
The lower triangle consists of elements on the anti-diagonal and below to it.
3
5 6
7 8 9
The sum of lower triangle elements is (3+5+6+7+8+9) equal to 38.
So the output should be
22
38
Sample Input
3 3
1 2 3
4 5 6
7 8 9
Learner's practices in relation to behavior, learning and teaching
Teacher's practices in relation to behavior, learning and teaching
A ball is thrown vertically upwards with an initial velocity of 30 m/s.
Using a time step of 0.02 s up to 6.20 s, write a matlab code to give a plot of the vertical distance versus
time for this ball.
Hint ; Motion under gravity is described by the equation : 𝑣𝑦 = 𝑣𝑜𝑦𝑡 +
1
2
𝑔𝑡
2
and gravitational acceleration 𝑔 is here taken as negative.
Then use your code to answer the following questions:
(i) To what maximum height does the ball rise?
(ii) What is the index of time at maximum height?
(iii) How long does it take the ball to ascend to maximum height?
(iv) How long does it take the ball to hit the ground?
(v) What happens to the ball if the sign for gravitational acceleration is taken as positive?
Learner's practices in relation to teachers
Learner's practices in relation to curriculum and resources