Objective:
Write a program that asks the user for the name of a file. The program should display
the last 10 lines of the file on the screen (the “tail” of the file). If the file has fewer than
10 lines, the entire file should be displayed, with a message indicating the entire file
has been displayed.
NOTE:
Using an editor, you should create a simple text file that can be used to test this
program.
2.83 g of a sample of haematite iron ore [iron (III) oxide, Fe2O3] were dissolved in concentrated hydrochloric acid and the solution diluted to 250 cm3. 25.0 cm3 of this solution was reduced with tin(II) chloride (which is oxidised to Sn4+ in the process) to form a solution of iron(II) ions. This solution of iron(II) ions required 26.4 cm3 of a 0.0200 mol/dm3 potassium dichromate(VI) solution for complete oxidation back to iron(III) ions.
(a) given the half–cell reactions
(i) Sn4+(aq) + 2e– ==> Sn2+(aq)
and (ii) Cr2O72–(aq) + 14H+(aq) + 6e– ==> 2Cr3+(aq) + 7H2O(l)
deduce the fully balanced redox equations for the reactions
(i) the reduction of iron(III) ions by tin(II) ions
(ii) the oxidation of iron(II) ions by the dichromate(VI) ion
(b) Calculate the percentage of iron(III) oxide in the ore.
Round the answer to this question to the nearest rand. David borrowed R911012,00
R911012,00 to refurbish his holiday home. The loan requires monthly repayments over 12 years. When he borrowed the money, the interest rate was 12,4% per annum, compounded monthly, but five years later the bank increased the annual interest rate to 13,9%, in line with market rates. After five years the present value of the loan is R682081,77
R682081,77. With the new interest rate, his monthly payments will increase by
A chopped meat mixture is formed by blending lean meat &fat ingre each consisteing 0.12 gm partcle sizeto produce an overall fat content 15%. After 10min of mixing eight sample of 3 gm each were taken from mixing bowl. Each sample was measured for fat content which give foll. Results expressed as 17.9%,23.3%,10%,13.3%,16.7%,26.7%6.7%12.2%.The mixtures was formed after mixing 10min from initial seprate ingredients of fat nd lean meat each composed of 0.12gm partcle .
A ) What would be expected value of mixing index after 15 min.mixing ?
B) What will be expected variance after 15min of mix?
C)If u were developing a schedule for this processing step what would be the recommended total mixing time nd why?
7. Use the oxidation number method to balance the following equations:
a) Al(s) + H2SO4 (aq) Al2(SO4)3 (aq) + H2 (g)
b) PbS(s) + O2(g) PbO (s) + SO2 (g)
26. Suppose that the tuition for a university is $10,000 this year and Write a program that computes the tuition in ten years and the total cost of four years"
increases 5% every year.
worth of tuition starting ten years from now. 27. Write a program that convert from kilograms to pounds, miles to kilometers, and from
hour to minutes based on the choice of the user. 28. Write a program that prompts the user to enter the number of students and each student's
name and score, and finally displays the student with the highest score and the student
with the second-highest score.
29. Write a program that prompts the user to enter the number of students and each student's name and score, and finally displays the name of the student with the highest score.
2. Write a float method triangle() that computes the area of a triangle using its two formal parameters h and w, where h is the height and w is the length of the bases of the triangle.
3. Write a float method rectangle() that computes and returns the area of a rectangle using its two float formal parameters h and w, where h is the height and w is the width of the rectangle.
4. The formula for a line is normally given as y= mx +b. Write a method Line() that expects three float parameters, a slop m, a y-intercept b, and an x-coordinate x. the method computes the y-coordinate associated with the line specified by m and b at x coordinate.
5. Write a method Intersect() with four float parameters m1.b1.m2,b2. The parameters come conceptually in two pairs. The first pair contains the coefficients describing one line; the second pair contains coefficients describing a second line. The method returns I
if the two lines intersect. Otherwise, it should return 0;
How many gram of potassium and iodine present in one kilogram of KI
Use the half-reaction method to balance the following equation and then identify the oxidizing and reducing agents:
Fe(OH)2 (s) + Pb(OH)3 -(aq) → Fe(OH)3 (s) + Pb(s) [basic]
Find out median for the following data
x: 10,15,18,23,27,30,31 f
20,30,40,50,60,70