ComputerScienceExpert

(11)

$18/per page/

About ComputerScienceExpert

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Applied Sciences,Calculus See all
Applied Sciences,Calculus,Chemistry,Computer Science,Environmental science,Information Systems,Science Hide all
Teaching Since: Apr 2017
Last Sign in: 103 Weeks Ago, 2 Days Ago
Questions Answered: 4870
Tutorials Posted: 4863

Education

  • MBA IT, Mater in Science and Technology
    Devry
    Jul-1996 - Jul-2000

Experience

  • Professor
    Devry University
    Mar-2010 - Oct-2016

Category > Programming Posted 23 May 2017 My Price 8.00

Lab Activity # GSP115-A7B. Lab 7

  • C++ Need questions answered only.
  • Part A
  • a. Why were you able to redefine whatStringIsThis multiple times in the program without an error?
  • b. Why is the output from func2() the only place we print out the global whatStringIsThis?
  • c. What happened to the whatStringIsThis that printed inside the while loop after it exited the loop?

d. What happened when you tried to create a string variable called whatStringIsThis after func2()? Why was this a problem here, but not anywhere else whatStringIsThis is defined?

 

Part B.

  • a. Is the Class based version of this code larger or smaller than the structure based version? Do you think this would be a typical result? Why?
  • b.How much programming had to be done to use the classes instead of structs in the range-based for loops in this program?
  • c. How much work did it take to make showStats() a class method instead of a general function?

d. What would you need to do to add a new weapon to this code?

 

A. Lab Activity # GSP115-A7B. Lab 7 of 7:Understanding Scope and Introducing Classes.C. Lab Overview – Scenario / Summary:TCO(s) that the lab supports:7Given a complex game problem, employ a complete menu-driven solution that includes a comprehensivestatement of the problem, complete program design, and program documentation, including comments.8Given a requirement for persistent data (such as saving a current game), design, code, and test a solutionalgorithm that reads input form the file and writes output to a file.Summary:You will experiment with code that demonstrates the concept of scope. You willexamine how a class is constructed.Learning outcomes:1.To be able to demonstrate an understanding of the effects of scope.2.To be able to discuss the key elements of a class.D. Deliverables:SectionDeliverablePart AStep 5. Program Listing and OutputPart BStep 5. Program Listing and OutputE. Lab Steps:Preparation:This lab requires Visual Studio 2012.qattachments_840cb6138e89c5d69fd0aac10ec392b346f17df9.docxPage 1

Attachments:

Answers

(11)
Status NEW Posted 23 May 2017 01:05 AM My Price 8.00

-----------

Attachments

file 1495501706-Solutions file 2.docx preview (51 words )
H-----------ell-----------o S-----------ir/-----------Mad-----------am ----------- Th-----------ank----------- yo-----------u f-----------or -----------you-----------r i-----------nte-----------res-----------t a-----------nd -----------buy-----------ing----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n. -----------Ple-----------ase----------- pi-----------ng -----------me -----------on -----------cha-----------t I----------- am----------- on-----------lin-----------e o-----------r i-----------nbo-----------x m-----------e a----------- me-----------ssa-----------ge -----------I w-----------ill----------- be----------- qu-----------ick-----------ly -----------onl-----------ine----------- an-----------d g-----------ive----------- yo-----------u e-----------xac-----------t f-----------ile----------- an-----------d t-----------he -----------sam-----------e f-----------ile----------- is----------- al-----------so -----------sen-----------t t-----------o y-----------our----------- em-----------ail----------- th-----------at -----------is -----------reg-----------ist-----------ere-----------d o-----------n -----------THI-----------S W-----------EBS-----------ITE-----------. ----------- Th-----------ank----------- yo-----------u -----------
Not Rated(0)