Форум программистов
 

Восстановите пароль или Зарегистрируйтесь на форуме, о проблемах и с заказом рекламы пишите сюда - alarforum@yandex.ru, проверяйте папку спам!

Вернуться   Форум программистов > IT форум > Помощь студентам
Регистрация

Восстановить пароль
Повторная активизация e-mail

Купить рекламу на форуме - 42 тыс руб за месяц

Закрытая тема
Ваша тема закрыта, почему это могло произойти? Возможно,
Нет наработок или кода, если нужно готовое решение - создайте тему в разделе Фриланс и оплатите работу.
Название темы включает слова - "Помогите", "Нужна помощь", "Срочно", "Пожалуйста".
Название темы слишком короткое или не отражает сути вашего вопроса.
Тема исчерпала себя, помните, один вопрос - одна тема
Прочитайте правила и заново правильно создайте тему.
 
Опции темы Поиск в этой теме
Старый 22.06.2018, 06:17   #1
Lupusludens
 
Регистрация: 05.11.2017
Сообщений: 4
По умолчанию Javascript. Нужна помощь в Домашней Работе. Need help in homework.

Javascript. Нужна помощь в Домашней Работе. Need help in homework.
Уе*ался. Get rid of, even pissed of.

Project 2
Next, create another XHTML page with a <script> block in the <head> section of the document. This script should include the following:
Create a function named whileTest(). Inside the function, create a variable named number and assign it a value between 1 and 10.
Create another variable named answer and assign it a value of 0 (zero).
Then create a while loop. Create code that will cause the loop to execute as long as the number variable does not equal the answer variable.
Inside the loop, assign the answer variable the return value from a prompt dialog box.
The prompt will ask the user to guess a number between 1 and 10. The loop will continue until the proper answer is entered.
After the loop exits, use an alert dialog box to inform the user of a correct guess.
Once you have the code working properly, create code that will allow the user only three guesses. If, after three guesses, the user has not entered the correct answer, exit the function and alert the user that he or she is out of guesses via an alert dialog box.
Ensure that only one dialog box appears after the function is exited, one with a correct guess message, or one asking the user to try again.
Experiment with different methods that you have seen for calling the function. You can use the load event or the onclick event handler of a form button.
Project 3
Now, create an XHTML page with a <script> block in the <head> section of the document. This script should include the following:
Create a for loop that will output the numbers one through 200.
Create code that ensures there is a space between each number.
Create code that will cause a line break after the output reaches 10, 20, 30, 40 and so on.
Create code that outputs the value of the loop counter variable after the for loop is exited.
Project 4
Finally, create an XHTML page with a <script> block in the <head> section of the document. This script should include the following:
Create a variable named color. Assign the result of a prompt dialog box as the value for the color variable.
The prompt dialog box will ask the user to select red, white or blue.
Create a switch statement. The test expression is the color variable converted to uppercase. Use RED, WHITE and BLUE after the case keywords.
As the code executes, reflect back to the user the selected choice.
Add a default clause that will execute if the user enters a choice other than those offered.
Remember that the user may click Cancel on the prompt dialog box. Create code before the switch statement to handle this eventuality.
Experiment with different ways of handling all the possible actions the user might take.
Lupusludens вне форума
Старый 22.06.2018, 07:43   #2
Alex11223
Старожил
 
Аватар для Alex11223
 
Регистрация: 12.01.2011
Сообщений: 19,500
По умолчанию

Тут не решатель задач.

Назовите нормально тему, покажите свои наработки, конкретные вопросы и т.п.
http://www.programmersforum.ru/announcement.php?f=31

Или в раздел Фриланс если вы не хотите ничего делать, а ищете кого-то, кто выполнит ваши задачи за вознаграждение.
Ушел с форума, https://www.programmersforum.rocks, alex.pantec@gmail.com, https://github.com/AlexP11223
ЛС отключены Аларом.
Alex11223 вне форума
Закрытая тема


Купить рекламу на форуме - 42 тыс руб за месяц



Похожие темы
Тема Автор Раздел Ответов Последнее сообщение
Нужна помощь по работе с файлами в С. kama4i Общие вопросы C/C++ 2 30.06.2015 09:21
Нужна помощь по работе с МИДИ файлами dim3740 Фриланс 1 08.04.2015 18:12
Программа по работе с текстами. Нужна помощь :( Verwolf Помощь студентам 4 08.07.2009 19:49
нужна помощь в работе с файлами gemoglobin Паскаль, Turbo Pascal, PascalABC.NET 2 08.07.2009 17:21
нужна помощь в работе с формой и БД Aliyushka Microsoft Office Excel 0 15.01.2009 23:54