<< Chapter < Page Chapter >> Page >
Questions, exercises, problems, etc. that support this chapter in the "Programming Fundamentals - A Modular Structured Approach using C++" collection/textbook.

Learning objectives

With 100% accuracy during a: memory building activity, exercises, lab assignment, problems, or timed quiz/exam; the student is expected to:

  1. Define the terms on the definitions as listed in the modules associated with this chapter.
  2. Install the Bloodshed Dev-C++ 5 compiler
  3. Make minor modifications to an existing program

Memory building activities

Link to: MBA 01

Exercises

    Answer the following statements as either true or false:

  1. Beginning programmers participate in all phases of the Systems Development Life Cycle.
  2. The Bloodshed Dev-C++ 5 compiler/IDE is the preferred compiler for this textbook/collection, however any C++ compiler will work.
  3. Most compilers can be installed on a flash drive.
  4. In addition to function as the name of a sub-program, the computer industry also uses macro, procedure and module.
  5. Generally functions fall into two categories: Program Control and Specific Task.

    Answers:

  1. false
  2. true
  3. false
  4. true
  5. true
Got questions? Get instant answers now!

Miscellaneous items

None at this time.

Lab assignment

Creating a folder or sub-folder for chapter 01 files

Within the Chapter 1 Connexions modules you were given directions on how to install the Bloodshed Dev-C++ 5 compiler/IDE and to test your installation with the Compiler_Test.cpp source code file. If you have not done this, return to the Connexions materials and complete this task.

In the compiler installation directions you were asked to make a folder named: Cpp_Source_Code_Files. All of your lab assignments in this course assume you have that folder on the same drive as your compiler (either drive C: your hard disk drive, or on a flash drive). If you don’t have that folder, go create it now.

Depending on your compiler/IDE, you should decide where to download and store source code files for processing. Prudence dictates that you create these folders as needed prior to downloading source code files. A suggested sub-folder for the Bloodshed Dev-C++ 5 compiler/IDE might be named:

  • Chapter_01 within the folder named: Cpp_Source_Code_Files

If you have not done so, please create the folder(s) and/or sub-folder(s) as appropriate.

Download the lab file(s)

Download and store the following file(s) to your storage device in the appropriate folder(s). You may need to right click on the link and select "Save Target As" in order to download the file.

Download from Connexions: Compiler_Test.cpp

Detailed lab instructions

Read and follow the directions below carefully, and perform the steps in the order listed.

  • Navigate to your sub-folder: Chapter_01 and rename the Compiler_Test.cpp source code file to: Lab_01.cpp
  • If you are having problems seeing the file extensions, visit the “Show Hide File Extensions” instructions within the Appendix.
  • Start your compiler and open the source code file. Carefully make the following modifications:
  • Change the comments at the top, specifically:
  • The filename should be: Lab_01.cpp
  • Purpose should be: Average the weight of three people
  • Remove the next 2 lines of comment talking about the main idea
  • Author: put your name and erase my name and copyright
  • Date: Put today's date
  • Remove the next 3 lines of comment dealing with licensing (don't erase the asterisk line)
During the rest of the course you will often use a source code file provided by the instructor as your starting point for a new lab assignment. Sometimes you will use a source code file that you have created as your starting point for a new lab assignment. Either way, you should modify the comments area as appropriate to include at a minimum the four lines of information (filename, purpose, author and date) as established in this lab assignment.
  • We are now going to make simple modifications to this program so that it is able to average the weight of three people. Do the following:
  • Within the variables area, change the variable names for age1 and age2 to weight1 and weight2. Add another variable of integer data type with the identifier name of weight3.
  • The input area has two prompts and requests for data from the user. They are paired up – a prompt and getting data from the keyboard. We need to modify the prompt to ask for weight instead of age. We need to change the variable name from age1 to weight1. Do this for the second pair that prompts and gets the second data item. Create a third pair that prompts and gets the third data item.
  • The process area has only one line of code and we need to make changes that add the weight3 and divides by 3.0 instead of 2.0. The code should look like this:
  • answer = (weight1 + weight2 + weight3) / 3.0;
  • The output area needs the text modified from ages to weights.
  • Build (compile and run) your program. You have successfully written this program if when it run and you put in the three weights; it tells you the correct average.
  • After you have successfully written this program, if you are taking this course for college credit, follow the instructions from your professor/instructor for submitting it for grading.

Problems

Problem 01a – instructions

List the steps of the Systems Development Life Cycle and indicate which step you are likely to work in as a new computer professional.

Questions & Answers

does psychology deal with love?
Mohammed Reply
Maybe, i think
edem
I definitely would say yes
Clara
how so
Isaiah
*triarchic
Meredith
there are so many different reasons why you can fall in love with someone, many of them develope subconsciously -> psychology
Clara
love messes with the brain, a lot, ergo I believe that Psychology does indeed deal with love
what is synapse
Katie Reply
In the central nervous system, a synapse is a small gap at the end of a neuron that allows a signal to pass from one neuron to the next. synapse are found where nerve cells connect with other nerve cells
Najeem
can you do auto book auto
Mariah Reply
WHT u mean?
usef
yes
MD
heyy, may i join the conversation please?
edem Reply
who is the father of psychology
Richy Reply
aristatil
Ramadevi
and please, how would you guys, describe the study of psychology at college ?
edem
psychologist student?
Aspen
i mean not yet but am about to start college so wanna know how is it(college in general and psychology course) please
edem
Psychology is the study of mind and behaviour. So if you will take psychology as a subject so you will get to know how your everything (physical, mental, social, spiritual aspects) effects your behaviour
sakina
With this brief knowledge you can help people to cope up with their problems and only you can guide them correctly
sakina
And if you go for further specialisations you can study hypnosis, face reading, body language etc
sakina
Thanks a lot🙏🏾 And ik some of the stuffs u said but i am also going to write thesis, right ?
edem
ok no prob, thanks a lot🙏🏾✨
edem
cerebellum
Khan
hae everyone, hope you are well this evning my question is what is the difference between drive and motivation
Michael
good question
Rainee
drive is more like an impulse or urge and i think they both go together (drive and motivation) even if there is a slight difference
edem
@ Michael Drive is delivered to be innate without the use of an external stimuli, motivation normally evolves an outside stimuli which may include praise, appreciate, or reward.
Reginald
*believed...sorry for typo
Reginald
@Reginald, can't the motivation come from the inner self?
edem
Good question, please give an example.
Reginald
can we say desire of success for example
edem
Wilhelm Wundt is the father of psychology
ipau
Wilhem Wundt thank you for the road that you opened.
Qwanta
You mean who is the father of having a great educated argumentative guess? nothing is more wrong than this question. The question is you should ask yourselfs is, how sure are you abour their scientific studying? one's percieved assimilated approach to judging another person and saying they are
Roger
the biggest problem with scientific research and data is that ya you could get the same result 1000 times then it could go the other way 1000 times, but we would never know that and we did, we would still say ya but the proof is there. The only thing science proves is that humanity has
Roger
no facts about human behavior in the scientific context, but more in the trial and error.. sorry to tell you, but so far no one has proven Father of anything, thats up to you and i, judgement is bias, science is good enough lazy
Roger
cognitive development is the growing and development of the brain.
Jessy Reply
Anyone knows about Techno-fascism?
Hussein Reply
Ecofascism is a theoretical political model in which an authoritarian government would require individuals to sacrifice their own interests to the "organic whole of nature". The term is also used as a rhetorical pejorative to undermine the environmental movement.
ipau
what's the big difference between prejudice and discrimination?
Danice Reply
A prejudiced person may not act on their attitude.  Therefore, someone can be prejudiced towards a certain group but not discriminate against them.  Also, prejudice includes all three components of an attitude (affective, behavioral and cognitive), whereas discrimination just involves behavior
Nancy Lee
hi
basher
hello
Rahul
what is all about cognitive development?
Kamohelo
cognitive development is the growing and development of the brain
Jessy
how do you control a variable when using spss whilst running a pearsons correlation analysis?
Jessie Reply
it dependa on your study. according to what you want to say and explain your result
Pouran
why does it say her and she
Jayla Reply
stages of cognitive development
brivia Reply
sensory preoperatinal concrete formal
Rajendra
what is psychology
Chethani Reply
the study of insecurities and the effect on the host .
Sera
Psychology is the scientific study of behavior & mental processes
Angela
psychology is science about learning human behaviour
Zhamshid
behaviorosm
Khan
In thinking about the case of Candace described earlier, do you think that Candace benefitted or suffered as a result of consistently being passed on to the next grade?
Nene Reply
what is reward
Angeles Reply
reward is a technique to change behaviour
Rajendra
Reward is a way to promote a specific behaviour or to teach someone/ something to behave a specific way or perform a specific task.
Johan
a reward is something that is usually associated with desirable behavior. The child got a reward for winning the game. A reinforcer is different in that a reinforcer is anything that increases behavior, even if it is increasing an undesirable behavior.
Meredith
reward is earned effort realized
freweini
why heroine addicted people smoke heroine in a dirty and polluted place ?
Najeem Reply
?
Sera
?
Sera
G
ky
/i don't know
Rajendra
🤔
Hammam
I believe they don't wanna be seen
Ruphine
Rajendra Singh I'm asking from those who know thanks for your comment
Najeem
Ruphine it's not a scientific answer
Najeem
Ok
Ruphine
more my personal opinions and experiences than a real answer but more of an answer than the question marks
Jehsika
what's the data or fact that actually say that heroine smokers host in dirty and polluted place.
amaan
Generally the more time an addict is using and the harder they use the more their life and everything around them crumbles. it's quite common to find neat respectable clean users but over time the addiction increases and their health declines along with their ability to keep up day to day duties.
Jehsika
I'll see if I can find some links for you to have a read.
Jehsika
hi. as heroine affedted exactly on the brain, it should be because the chages heroine makes on frintal lobe and sensory and motor parts. after a while the cannot behave in a normal way. in a way heroine ruines the neurones
Pouran
The things said in the thread are some of the most horridly presumptuous & unwarrantedly pretentious statements I've read in my entire life. It's distastefully disrespect, to say the least.
Kaytee
Pouran Hi! thanks for answering I'm agree with your opinion and may the answer be the same
Najeem
Got questions? Join the online conversation and get instant answers!
Jobilize.com Reply

Get the best Algebra and trigonometry course in your pocket!





Source:  OpenStax, Programming fundamentals - a modular structured approach using c++. OpenStax CNX. Jan 10, 2013 Download for free at http://cnx.org/content/col10621/1.22
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Programming fundamentals - a modular structured approach using c++' conversation and receive update notifications?

Ask