We are here with you hands in hands to facilitate your learning & don't appreciate the idea of copying or replicating solutions. Read More>>

Looking For Something at vustudents.ning.com? Click Here to Search

www.bit.ly/vucodes

+ Link For Assignments, GDBs & Online Quizzes Solution

www.bit.ly/papersvu

+ Link For Past Papers, Solved MCQs, Short Notes & More

 

Question:                                                                        

Write a program that computes the average and standard deviation of the text floating point numbers in a file. Use the following formulas for the average and the standard deviation of N values. The formulas compute the sum, the sum of squares, the average, the average square, the variance, and finally, the standard deviation.

sum = x1 + x2  + x3 + ... + xN-1 + xN

 

sumSQ = x12 + x22  + x32 + ... + xN-12 + xN2

 

avg = sum/N

 

avgSQ = avgSQ/N

 

var = avgSQ - avg2

 

sd  = var(1/2)

The input file will contain any number text floating point numbers, similar to the following:

10.5

12.9

9.67

12.05

8.23

10.08

10.23

7.7

10.4

11.34

Numbers could be several, or none per line, and negative numbers are perfectly OK.

 

Note: All the source code should be written manually. Your code must justify enough for 15 marks.

 

 

Lectures Covered: This assignment covers Lecture # 01-09

Deadline

Your assignment must be uploaded/submitted at or before 31/10/2011.          

 

+ How to Follow the New Added Discussions at Your Mail Address?

+ How to Join Subject Study Groups & Get Helping Material?

+ How to become Top Reputation, Angels, Intellectual, Featured Members & Moderators?

+ VU Students Reserves The Right to Delete Your Profile, If?


See Your Saved Posts Timeline

Views: 3864

.

+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

+ Click Here to Search (Looking For something at vustudents.ning.com?)

+ Click Here To Join (Our facebook study Group)

Attachments:

Replies to This Discussion

Upload Solution File

Myspace text generator

kashif u have Solution ? if yes please share here

Nai brother mere pass solution nai hay ,,,,,,, Still trying to solve ....

any body reply time is short  please reply hurry.........................

yar kisi say b nai bani abi tak? me say yar data file say nikal nai raha file say nikal jai to assignment bn gae

try ho rahi hy ab dekhen

new modified assignment has been uploaded by our teacher.

new modified formula

 

avgSQ = avgSQ/N  ---- goes to  avgSQ = sumSQ/N

please not

Brother MT sh this is right formula donot Worry

 

mateen Brother during the execution of the code input file not found ka error a raha ha where should be the input file copied.

 

import java.io.*;

public class Assignment1 { public static void main(String args[]){

FileReader fr=null;

BufferedReader br=null;

try{ fr=new FileReader("input.text");

br=new BufferedReader(fr);

String s=br.readLine(); while(s!=null); {

System.out.println(s);

s=br.readLine();}

br.close();

fr.close(); }

catch(IOException ioex){

System.out.println(ioex); }

}
}

  • File not found ka message print ho raha ha kase thek ho ga

RSS

Latest Activity

+¢αяєℓєѕѕ gιяℓ replied to Moji's discussion Assignment #1 Semester FALL 2019 Physics (PHY101)
40 minutes ago
Asmat replied to + "J ɨ y ą ⋆'s discussion CS501 Assignment No 01 Fall 2019 Solution & Discussion Due Date: 12-11-2019 in the group CS501 Advance Computer Architecture
59 minutes ago
+!!! NOOR UL JANAT !!!+ replied to Rana Ali's discussion Alfaz
1 hour ago
Rana Ali replied to Rana Ali's discussion Alfaz
2 hours ago
Rana Ali liked Rana Ali's discussion Alfaz
2 hours ago
Rana Ali liked Rana Ali's discussion Psy511 assignment no 1
2 hours ago
Rana Ali added a discussion to the group PSY511 Environmental Psychology
2 hours ago
Rana Ali liked + M.Tariq Malik's group PSY511 Environmental Psychology
2 hours ago
Rana Ali joined + M.Tariq Malik's group
2 hours ago
Rana Ali liked + M.Tariq Malik's discussion EDU302 Human Development and Learning Assignment No 01 Fall 2019 Solution & Discussion
2 hours ago
MUHAMMAD USMAN replied to MIT's discussion Operating Systems(CS604) Assignment # 01 Deadline Date 16-11-2019 in the group CS604 Operating Systems
2 hours ago
Muhammad Awais replied to Usman Mughal's discussion Assignment No. 01 Semester: Fall 2019 in the group CS101 Introduction to Computing
3 hours ago
Muhammad Awais joined + M.Tariq Malik's group
3 hours ago
Farhan Amin replied to Farhan Amin's discussion your vu email address will deleted
4 hours ago
Farhan Amin replied to Farhan Amin's discussion your vu email address will deleted
4 hours ago
+ ! ! ! ! ! AaiMa AnsaRi liked + M.Tariq Malik's discussion CS201 Assignment No 01 Fall 2019 Solution & Discussion Due Date: 14-11-2019
4 hours ago
+ ! ! ! ! ! AaiMa AnsaRi replied to + M.Tariq Malik's discussion MGT211 GDB Fall 2019 Solution & Discussion in the group MGT211 Introduction To Business
4 hours ago
+ ! ! ! ! ! AaiMa AnsaRi joined + M.Tariq Malik's group
4 hours ago
+ ! ! ! ! ! AaiMa AnsaRi liked + M.Tariq Malik's discussion MGT211 GDB Fall 2019 Solution & Discussion
5 hours ago
+ Abb@s replied to Farhan Amin's discussion your vu email address will deleted
5 hours ago

Today Top Members 

© 2019   Created by + M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service