Search:
Type: Posts; User: TheStorm
Search:
Search took 0.03 seconds.
-
March 25th, 2009, 01:44 PM
This is as far as I got. Dont know if it makes any sense. The idea is that I will be able to interchange the char used to create the triangle.
// Draws a triangle
#include <iostream>
using...
-
March 25th, 2009, 11:12 AM
Thank you Alan, I thought "void displayOneLine(int sizeP)" was declairing only one int. Also the code below only shows # on the screen, in a continious loop. Not sure why but whenever I use "="...
-
March 25th, 2009, 10:51 AM
That worked a treat thank you. Now I would like to chnage the void function to only use one int statement. I tried the following but it does not work. Feels like the more I learn the more I dont...
-
March 25th, 2009, 07:21 AM
Here is what I have managed to do so far. The last thing I need to do is add an additional line at the top to complete the triangle. Below is the output that I get at the moment.
...
-
March 25th, 2009, 01:30 AM
Hallo all, I am trying to create a program that will draw a nice little picture using ASCII. So far I have managed to draw half the triange I intended. My question is how would I draw the rest of the...
-
March 24th, 2009, 08:25 AM
That's what the assignment said.
-
March 24th, 2009, 08:12 AM
Thank you for your responses. The assignments requirements are that x must count towards the spoilt votes.
-
March 24th, 2009, 07:58 AM
Finally it works. Thank you for all your help.
Here is the final code:
#include <iostream>
using namespace std;
-
March 24th, 2009, 07:34 AM
Thank you but the original assignment states that I can not use do..while. Part of the construct is given and it does not include do...while statemts.
-
March 24th, 2009, 07:13 AM
One last thing I need the code to see any character other than A B C as a spoilt vote. This should include X, as it stands now it reads every character except A B C and X as a spoilt vote.
-
March 24th, 2009, 07:02 AM
Changing the code to below worked. Thank you for your help.
//Loop over voters
cout << "Who are you voting for (A,B or C)? " << endl;
cin >> vote;
while ( vote != 'X' &&...
-
March 24th, 2009, 04:47 AM
You are right, what I meant to say was nested while statement. As I assume you know by now this is all pretty new to me and all the terms are at times confusing.
-
March 24th, 2009, 04:29 AM
Maybe this reads better:
#include <iostream>
using namespace std;
int main ()
{
-
March 24th, 2009, 12:01 AM
Even if I exclude the vote in:
cout << "Who are you voting for (A,B or C)? " << endl;
cin >> vote; // This vote will never be counted
The votes still dont add up also how would i include the...
-
March 23rd, 2009, 03:00 PM
Yet another question from a student. For a assignment I was asked to create a program that will calculate the amount of votes in a election. There are four voting stations and three candidates.
...
|
Click Here to Expand Forum to Full Width
|