No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
Re:
string rating(bool ozone, bool no2, bool so2) { string result; int count = 0; if(ozone == true) { count++; } if(no2 == true) count++; if(so2 == true) count++; if(count == 3) result = "Gold Star"; if(count == 2) result = "Silver Star"; if(count == 1) result = "Ok"; if(count == … |
|
Re:
As part of a project I'm working on, I need to develop a program that can take in a sentence and convert it somehow (I'm choosing to convert into Pig Latin). At first I thought this was going to be a piece of cake, until I realized that after [code]#include … |
|
Re:
Ok I know how to sort an array. That's not what I'm asking. Basically my problem analysis is: I have to read in a file of employee reports ie salesID Employee code numunits numdollars 6022 1 3 100.00 6023 1 6 200.00 ok so I read each value into arrays … |
|
Re:
I'm trying to convert a string to an integer and store it in the same variable multiple time through a loop. For some reason it never works after the first time, it screws the number up. [code] #include <stdlib.h> #include <string> #include <iostream> #include <cstdio> #include <sstream> using namespace std; … |
|
Re:
[code=cplusplus] // New2.cpp : Defines the entry point for the console application. // #include "stdafx.h" #include <iostream> #include <iomanip> #include <string> using namespace std; void reverse(string& s); int _tmain(int argc, _TCHAR* argv[]) { string st="Word" ; cout<<st<<"\n"; reverse(st); cout<<st<<"\n"; return 0; } void reverse(string& st) { int i; int j … |