No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
19 Posted Topics
Re: You need to show us some efford before we can help you xD | |
Ok i have a calculator program, but it can only do positive numbers, can anyone point me in the direction to make it get negative numbers also? [code]#include <iostream> #include <iomanip> using namespace std; struct Node{ float number; Node *next; }; Node* push(Node *stack, float data){ Node *utility; utility = … | |
Re: This might help you [code] #include <iostream> #include <conio.h> using namespace std; int main()//you should use int main not void main { int i, j, k, rows; cout<<"Specify the number of rows (between 1-19) in the dimond: "; cin>>rows; cout<<endl; for(i=1; i<=rows; i++) { for(j=1; j<=rows-i; j++) cout << " … | |
Re: have you tried n=0.0 or making it a double too | |
Re: You need to post some code, so that we can help you. | |
Re: ok maybe you are looking for something like this study it im pretty sure its what you want to order the array in descendent order [code] for(int m=0;m<length;m++) { for(int j=0; j<(length-1); j++) { if(num2[j]<num2[j+1]) { temp=nums[j]; nums[j]=nums[j+1]; nums[j+1]=temp; } } }[/code] btw you should post your code in the … | |
Re: [code] #include <iostream> using namespace std; int main() { //code goes here return 0; }[/code] That`s about it, the law says so. start coding something and post it. | |
Re: you could try [code] system("pause"); [/code] or [code] #include <conio.h>//this library is needed for getch() getch(); [/code] right before the return command on your main | |
Re: wow you really are jumping some pages on that book of yours, start with the most basic things like in your first post when you get that all figured out keep going | |
Re: Well there are somethings you might not be understanding, or not looking from the right side Here is a code that might give you a hand, didnt tested it but is just for you to get an idea of how to read the different kind of data [code]#include <iostream> #include … | |
Well basicly the problem is that i have to call the function push while the char that is asked for is not '0' then i have to send the modified "*top" and "*temp" into the function POP so that i can show the values and do the deleting of the … | |
Re: you could use [code] while(!dict.eof())//this will make it keep going untill the end of line { dict.getline(words,sizeof(dict));//this will read line by line }[/code] hope it helps | |
Re: you can also use only the [code]fstream test; test.open("name of file") while(!test.eof)//.eof means while is not the end of file. { //condition } [/code] | |
Re: Pretty much the same way as in your last post, but you have to do a condition after the while something like [code]if( in == '(' ) { in[i++] // this is to jump the space of the parenthesis and //go to next position. } //continue reading as before and … | |
Re: In the condition [code]if(answer='y'||answer=='Y') data.open("Person.txt")[/code] What is it that you are trying to do exactly? I'm not sure but for the threat i can assume you want it to show the content of Person.txt, if i am right and you want it to show the content what are you doing … | |
Ok well i need help with my code, the idea is to make something like a DOS Console, the trick is we are not alowed to use dos functions. Well this is what i have so far [code] #include <stdio.h> #include <iostream.h> #include <conio.h> #include <string.h> #include <dir.h> #include <dos.h> … ![]() | |
Re: Check your line 30, you are comparing or do you want startcheck to become true? This will check if startcheck equals true: startcheck==true; This will make startcheck become true: startcheck=true; | |
Well I have a doubt about where can I find some examples about this funcion, I need to use it on a program. Any ideas are welcome xD | |
Im new on this forum, i don`t really know if this should go hear or somewhere else. If i messed up well sry. Here is the problem im working for the first time in Turbo C, i have this proyect its a simple one but i still need help. The … |
The End.