Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
4th Edition
ISBN: 9780134444321
Author: Tony Gaddis
Publisher: PEARSON
bartleby

Videos

Textbook Question
Chapter 6, Problem 11PE

Personal Web Page Generator

Write a program that asks the user for his or her name, then asks the user to enter a sentence that describes himself or herself. Here is an example of the program’s screen:

Enter your name: Julie Taylor Chapter 6, Problem 11PE, Personal Web Page Generator Write a program that asks the user for his or her name, then asks the

Describe yourself: I am a computer science major, a member of the Jazz club, and I hope to work as a mobile app developer after I graduate.

Once the user has entered the requested input, the program should create an HTML file, containing the input, for a simple Web page. Here is an example of the HTML content, using the sample input previously shown:

<html>

<head>

</head>

<body>

<center>

<hl>Julie Taylor</hl>

</center>

<hr />

I am a computer science major, a member of the Jazz club, and I hope to work as a mobile app developer after I graduate.

<hr />

</body>

</html>

Blurred answer
Students have asked these similar questions
23. Personal Web Page GeneratorWrite a program that asks the user for his or her name, and then asks the user to enter a sentence that describes him or herself. Here is an example of the program’s screen: Enter your name:  Julie Taylor [Enter] Describe yourself: I am a computer science major, a member of the Jazz club, and I hope to work as a mobile app developer after I graduate. [Enter]Once the user has entered the requested input, the program should create an HTML file, containing the input, for a simple Web page. Here is an example of the HTML content, using the sample input previously shown: <html><head></head><body>  <center>     <h1>Julie Taylor</h1>  </center>  <hr />  I am a computer science major, a member of the Jazz club,  and I hope to work as a mobile app developer after I graduate.  <hr /></body></html> 1. want to use condition loop to complete
GirlNames.txt This file contains a list of the 200 most popular names given to girls born in the United States from the year 2000 through 2009.  BoyNames.txt This file contains a list of the 200 most popular names given to boys born in the United States from the year 2000 through 2009. Write a program that reads the contents of the two files into two separate lists. The user should be able to enter a boy’s name, a girl’s name, or both, and the application will display messages indicating whether the names were among the most popular. **programming language is python** ** must use a def main(): function** *please include some comments*  i aslo have the .txt files but no wya to upload them
Topical Information Use C++. This lab will give you practice using the String class we developed in lecture (as well as some more help with randomness and files). Program Information Allow the user the choice of displaying either a random line or a random word from a file they specify. Your menu should allow them to choose these options either from the number of the option or from the capitalized letter. For example, 1) display random Word 2) display random Line 3) Quit Should allow the user to select a random line display by either entering the number 2 or by entering a letter L (lower or upper case!).

Chapter 6 Solutions

Starting Out with Python (4th Edition)

Ch. 6.1 - In what mode do you open a file if you want to...Ch. 6.2 - Write a short program that uses a for loop to...Ch. 6.2 - Prob. 13CPCh. 6.2 - Assume the file data.txt exists and contains...Ch. 6.2 - Prob. 15CPCh. 6.3 - Prob. 16CPCh. 6.3 - Prob. 17CPCh. 6.3 - Prob. 18CPCh. 6.4 - Prob. 19CPCh. 6.4 - Prob. 20CPCh. 6.4 - What type of exception does a program raise when...Ch. 6.4 - Prob. 22CPCh. 6 - A file that data is written to is known as...Ch. 6 - A file that data is written to is known as...Ch. 6 - Before a file can be used by a program, it must be...Ch. 6 - When a program is finished using a file, it should...Ch. 6 - The contents of this type of file can be viewed in...Ch. 6 - This type of file contains data that has not been...Ch. 6 - When working with this type of file, you access...Ch. 6 - When working with this type of file, you can jump...Ch. 6 - This is a small holding section" in memory that...Ch. 6 - This marks the location of the next item that will...Ch. 6 - When a file is opened in this mode, data will be...Ch. 6 - This is a single piece of data within a record. a....Ch. 6 - Prob. 13MCCh. 6 - Prob. 14MCCh. 6 - Prob. 15MCCh. 6 - When working with a sequential access file, you...Ch. 6 - When you open a file that file already exists on...Ch. 6 - The process of opening a file is only necessary...Ch. 6 - Prob. 4TFCh. 6 - When a file that already exists is opened in...Ch. 6 - Prob. 6TFCh. 6 - You can have more than one except clause in a...Ch. 6 - Prob. 8TFCh. 6 - Prob. 9TFCh. 6 - Describe the three steps that must be taken when a...Ch. 6 - Why should a program close a file when it's...Ch. 6 - What is a read position? where is the read...Ch. 6 - If an existing file is opened in append mode, What...Ch. 6 - If a file does not exist and a program attempts to...Ch. 6 - Write a program that opens an output file with the...Ch. 6 - Write a program that opens the my_name.txt file...Ch. 6 - Write code that does the following: opens an...Ch. 6 - Prob. 4AWCh. 6 - Modify the code that you wrote in problem 4 so it...Ch. 6 - Write code that opens an output file with the...Ch. 6 - A file exists on the disk named students. txt. The...Ch. 6 - A file exists on the disk named students txt. The...Ch. 6 - Prob. 9AWCh. 6 - Prob. 10AWCh. 6 - File Display Assume a file containing a series of...Ch. 6 - File Head Display Write a program that asks the...Ch. 6 - Line Numbers Write a program that asks the user...Ch. 6 - Item Counter Assume a file containing a series of...Ch. 6 - Sum of Numbers Assume a file containing a series...Ch. 6 - Average of Numbers Assume a file containing a...Ch. 6 - Random Number File Writer Write a program that...Ch. 6 - Random Number File Reader This exercise assumes...Ch. 6 - Prob. 9PECh. 6 - Golf Scores The Springfork Amateur Golf Club has a...Ch. 6 - Personal Web Page Generator Write a program that...Ch. 6 - Average Steps Taken A Personal Fitness Tracker is...

Additional Engineering Textbook Solutions

Find more solutions based on key concepts
Knowledge Booster
Computer Science
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • # NumberFun.py # using multiple functions. # copy/paste this program to run it first, you are supposed to use Google Chrome as Internet Browser for this course. # 1. calculate sum of the first n natural numbers, e.g.:1,2,3,... def sumN(n): sumN = 0 for i in range(1,n+1): sumN = sumN + i return sumN # 2. calculate sum of the square of the first m natural numbers, e.g.:1,4,9,... ### After you define/write/complete the function sumMSquare(m), remove the # sign as below to ENABLE next line of code ####def sumMSquare(m):### YOUR TURN TO DEFINE/WRITE/COMPLETE function sumMSquare(m) as below, based on sumN(n) # 3. call two functions defined previously within main() function def main(): print("This program computes the total and total of squares of the first") print("N/M natural numbers.\n") n,m = input("Please enter a value for N and M: ").split(",") print("The total of the first", n, "natural numbers is", sumN(int(n)))### After you define/write/complete the function sumMSquare(m), remove…
    1994 Weekly Gas GraphIn the student sample programs for this book, you will find a text file named 1994_Weekly_Gas_Averages.txt. The file contains the average gas price for each week in the year 1994.(There are 52 lines in the file.) Using matplotlib, write a Python program that reads thecontents of the file then plots the data as either a line graph or a bar chart. Be sure to displaymeaningful labels along the X and Y axes, as well as the tick marks.   (in python)
    C lanaguge    Managing Student Information! C LANGUAGE We're going to build a student information management system. The user should be shown a menu with four options: display student initials, display student GPAs, add students, or exit the program. If the user chooses to exit, the program should end. Otherwise, if the user chooses to display the student initials, the contents of the students.txt file should be read, and just the student number and initials should be displayed to the user in a tabular format. If the user chooses to display the student GPAs, the contents of the students.txt file should be read, and just the student number and GPAs should be displayed to the user in a tabular format. If the user chooses to add students, they should be prompted for the number of studnets they’d like to add. They should then be prompted that many times for a studnet number, a GPA, a first initial, and a last initial. Each of the new items should be saved to the students.txt file.…
  • # NumberFun.py # using multiple functions. # copy/paste this program to run it first, you are supposed to use Google Chrome as Internet Browser for this course. # 1. calculate sum of the first n natural numbers, e.g.:1,2,3,... def totalN(n): totalN = 0 for i in range(1,n+1): totalN = totalN + i return totalN # 2. calculate sum of the cube of the first m natural numbers, e.g.:1,8,27,... ### After you define/write/complete the function totalMCube(m), remove the # sign as below to ENABLE next line of code ###def totalMCube(m):### YOUR TURN TO DEFINE/WRITE/COMPLETE function totalMCube(m) as below, based on totalN(n) # 3. call two functions defined previously within main() function def main(): print("This program computes the total and total of cubes of the first") print("N/M natural numbers.\n") n,m = input("Please enter a value for N and M: ").split(",") print("The total of the first", n, "natural numbers is", totalN(int(n)))### After you define/write/complete the function totalMCube(m),…
    Sum of Numbers in a String Create an application that lets the user enter a string containing series of numbers separated by commas. Here is an example of valid input: 7,9,10,2,18,6 The program should calculate and display the sum of all the numbers.
    Computer Science The program below uses a class, DomainAvailabilityTools, which includes a table of registered domain names. The main function prompts for domain names until the user presses Enter at the prompt. The domain name is checked against a list of the registered domains in the DomainAvailabilityTools class. If the domain name is not available, the program displays similar domain names.   #include <iostream>#include <string>#include <cctype>#include "DomainAvailabilityTools.h"using namespace std; // *********************************************************************** // prompts user string. Returns string.string GetString(string prompt) {string userInput;  cout << prompt << endl;cin >> userInput; return userInput;}// *********************************************************************** int main() {const string PROMPT_DOMAIN_NAME ="\nEnter a domain name to check availability (Enter to exit): ";DomainAvailabilityTools dvTools; string…
  • n the starting-code below, <string> is not #included, but <cstring> is. You should also #include <string>. <cstring> is only included in case you want to use strlen("_photo.jpg"). It's up to you whether you want to use that. A photographer is organizing a photo collection about the national parks in the US and would like to annotate the information about each of the photos into a separate set of files. Write a program that reads the name of a text file containing a list of photo file names. The program then reads the photo file names from the text file, replaces the "_photo.jpg" portion of the file names with "_info.txt", and outputs the modified file names. Assume the unchanged portion of the photo file names contains only letters and numbers, and the text file stores one photo file name per line. If the text file is empty, the program produces no output. Ex: If the input of the program is: ParkPhotos.txt and the contents of ParkPhotos.txt are:…
    (Phone key pads) The international standard letter/number mapping found on the telephone is shown below:Write a program that prompts the user to enter a lowercase or uppercase letter and displays its corresponding number. For a nonletter input, display an invalid input message. Here are sample runs:   Welcome to PhoneKeypad Mapping Program by Mrs Jackson   Enter a letter from phone keypad: 2 ** INVALID INPUT !!  ** ----------------------------------------------------------------------------------------------   Welcome to PhoneKeypad Mapping Program by Mrs Jackson   Enter a letter from phone keypad: F *The corresponding letter is 3
    Palindrome Checkercreate a JavaScript program that checks if phrasesentered by the user are palindromes. A palindrome is a word, number, phrase, or other sequence of characters which reads the same backward as forward, such as “SIR”,“raceBIKE”, “Never odd or even”, “20/1/20”. The program should prompt the user to typein a phrase that is at least three characters long, and then tell the user whether the phrasewas a palindrome. Note, the decision should be based solely on letters and numericaldigits, and so it should not consider other characters, such as spaces or exclamationmarks, even though these might be entered by the user. when checking palindromes.A. Select your test data with care. Both palindromes and non-palindromes would be included in this. Provide examples that are text, numeric, and mixed; ignore any additional characters and spaces; andB. Ask the user for the word and then read their input. To verify that their input string has been read correctly, test this by displaying…
  • Data File: Example #1AAAAABBBBBCCCCCDDDDDAAEBCBAFBBCDCECDADDEFEEFFFExample #2AAATAABTBBBBCCCCTCDDTDDDAASAABBSBBCCSCCDSDDDEEEAEEFBFFFDDF Write a program that will give the user a brief introduction, then allow the user to type in the name of the file to be analyzed, the name of the data file to generate, and then process the data to match the output that is shown below. This DNA test measures the various parts of the sequence and assigns them a letter. While the letters could be anything from A to Z, the only letters that matter for this test are the letters {A,B,C,D} all other letters can be ignored completely. A sample will be tested, given a length of time and then tested again. Each time the scientist will generate a line of data. Here is one Example: Example #1 AAAAABBBBBCCCCCDDDDD AAEBCBAFBBCDCECDADDEFEEFFF At first glance the sample looks significantly different after the second test. But if you look at the data, you will note that since we only care about A,B,C,D’s that the…
    Computer Science Using Java language Write a procedure that generates a regular heightfield in data-files/model/heightfield.off with elevation given by the grayscale values of an image file. Use a file dialog to select the file, a number box to scale the xx and zz integer coordinates by, and a number box to set the scale that 1.0 corresponds to for height. Make a button labelled “Generate” that launches the generator. Display a message on screen while generating and then flush the G3D::ArticulatedModel cache, and reload the current scene on completion.
    scores.txt : Jan,86 Drew,92 Blake,85 Alex,81 Taylor,88 Jordan ,72Cam,89       Note: code is written in python please   The file scores.txt (attached) contains a list of names and test scores. Create a program that reads each line of the file and determines the highest score and who obtained it. This is an exercise in strings. You are required to use at least one string method to determine the names and the scores. Your output should resemble the following: Highest Score: 100Achieved by: Jay Note; i could not send an attachment of the actual file but  i have copied its contents.
    • SEE MORE QUESTIONS
    Recommended textbooks for you
  • EBK JAVA PROGRAMMING
    Computer Science
    ISBN:9781337671385
    Author:FARRELL
    Publisher:CENGAGE LEARNING - CONSIGNMENT
    C++ Programming: From Problem Analysis to Program...
    Computer Science
    ISBN:9781337102087
    Author:D. S. Malik
    Publisher:Cengage Learning
    Programming with Microsoft Visual Basic 2017
    Computer Science
    ISBN:9781337102124
    Author:Diane Zak
    Publisher:Cengage Learning
  • EBK JAVA PROGRAMMING
    Computer Science
    ISBN:9781337671385
    Author:FARRELL
    Publisher:CENGAGE LEARNING - CONSIGNMENT
    C++ Programming: From Problem Analysis to Program...
    Computer Science
    ISBN:9781337102087
    Author:D. S. Malik
    Publisher:Cengage Learning
    Programming with Microsoft Visual Basic 2017
    Computer Science
    ISBN:9781337102124
    Author:Diane Zak
    Publisher:Cengage Learning
    C - File I/O; Author: Tutorials Point (India) Ltd.;https://www.youtube.com/watch?v=cEfuwpbGi1k;License: Standard YouTube License, CC-BY
    file handling functions in c | fprintf, fscanf, fread, fwrite |; Author: Education 4u;https://www.youtube.com/watch?v=aqeXS1bJihA;License: Standard Youtube License