Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and beginning April 20th, 2021 (Eastern Time) the Yahoo Answers website will be in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
Trending News
Need serious javascript/html help..willing to pay?
Objective: Create a webpage that finds the median, mode and average of a set of numbers input by the user. The user will first be requested to enter a number which represents the number of numbers they will enter (maximum number is 20). The web page will then request the user to enter, one at a time, the number of numbers they specified.
Anyone who can code that for me..i will pay via paypal $30
The code you posted does not work..in fact it shows a blank screen on Internet Explorer
4 Answers
- 1 decade agoFavorite Answer
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<SCRIPT LANGUAGE="JavaScript">
<!--
alert("This is Just a part of the code te full version will be updated on request");
var num_field;
function genfield()
{
var field_div = document.getElementById('fields');
num_field = document.getElementById('num').value;
if(num_field > 20)
{
alert("Value too High try some value below 20");
return false;
}
var app = '';
for( var i = 0; i< num_field ; i++)
{
app += 'Enter Value '+(i+1)+' : <input type =text id =inf_'+i+'><br>';
}
app += '<input type =button id =calc onclick=calc() value=Calculate>';
// alert(app)
field_div.innerHTML = app;
}
function calc()
{
var avg = 0;
var num;
var t = new Array(num_field);
for(i = 0; i< num_field ; i++)
{
num = document.getElementById('inf_'+i).value
avg = avg * 1;
avg = avg - (-num);
}
avg = avg / num_field;
alert ("Average of "+num_field+" Number = "+avg)
}
</SCRIPT>
<TITLE>Test PAge</TITLE>
</HEAD>
<BODY>
Enter The Number of values you wish to find median, mode and average the numbers: <br>
<input type = "text" id = "num">
<input type = "button" id = "gen" value = "Generate Fields" onclick="genfield()">
<input type="hidden" value="0" id="theValue" />
<!-- <p><a href="javascript:;" onclick="addElement();">Add Some Elements</a></p> -->
<br><Br><hr>
<div id="fields"> </div>
</BODY>
</HTML>
hope it was helpful drop in your comments at sandepn@rocketmail.com
- lyngLv 44 years ago
He performed a key place with Kohli interior the run chase against Pakistan.He gave his wicket away against RSA looking for greater runs..it fairly is in basic terms a count of time whilst he would be back with a bang.He has been a damn relaxing batsman & will proceed to be..!! & @ leaping solar,I agree that Rohith could he skipped over & could provide probability for others.yet I strongly disagree with the point out of Raina with Rohit.Raina has completely cemented his place interior the Indian group & there is not any question of removing him.he's the optimal run scorer for India in T20s,& the optimal ranked Indian batsman in ICC T20 scores.he's the only Indian to attain centuries in all 3 formats of the recreation.He performed a key place in India's win over Austalia in quarter finals of WC 2011 with Yuvraj Singh & against Pakistan interior the semi-finals with out which India could desire to no longer have qualified for the finals..He replaced into in contact in a great partnership with Kohli against Sri Lanka the place India chased 321 in 37 overs..India's batting could get a hell lot weakened with out Suresh Raina.His contribution in direction of he end of the innings holds the considerable for India.it may look fairly humorous if people ever dare to question Raina's place interior the group(fairly in constrained overs cricket)..people defined Raina because of fact the subsequent Sachin tendulkar of Indian cricket throughout the time of the early days of his profession.,to whose point he could desire to no longer strengthen as for this reason of his decrease batting order place at no.6..,yet he performs an important place to India by no longer in basic terms including intensity to Indian batting,yet in addition along with his spectacular fielding..!!
- 1 decade ago
Hmmm this could be done in many ways. HTML is just the front-end i.e. what they see. You could do php, or ajax which in my opinion is better.
- Anonymous1 decade ago
I can do this for you. Mail me at
alan@webmarketingexperts.com.au