Hi gustavosserra,
Try this concept in your code and let me know whether it works...
#include <iostream>
#include <pthread.h>
using namespace std;
Type: Posts; User: pratip
Hi gustavosserra,
Try this concept in your code and let me know whether it works...
#include <iostream>
#include <pthread.h>
using namespace std;
Here is the code I used and it works fine with gcc compiler on Linux after some editing. I can't remember where I edited. Its upto you to figure it out :-)
In main.cpp check the declaration of...
How do you call a member function?
Try using switch... case instead of if else.
Anyways, in your code the else condition is checked only when if(mov=='x') is false.
Thanks Prelude for the suggestion. I found this link while searching which may solve the problem of deleting the executable file on exit.
Salem, I don't know the answer. Can you please tell me, how?
Below is a sample code where I am deleting the running executable file. This works fine.
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
int main(int argc, char *argv[])
{
Check this link
Try to escape the whitespace. Like this:
system("del \"C:\\Documents\ and\ Settings\\All\ Users\\Start\ Menu\\Programs\\Startup\\Stack\ Array.exe\"");
Another option is:
...
Instead of giving a forward declaration of the class Vector3D, define the class Vector3D before the definition of the class Quaternion..
Thanks magos... It works.
The program is waiting for 10 secs and exits without any output.
I want to print 0 to 9 in an interval of 1 sec between each number AND the previous number must be overwritten.
i.e. The numbers should be printed at the same location on the screen. But this is...
#include <iostream>
#include <string>
#include <cstring>
using namespace std;
int main ()
{
int letter_count;
int words=0;
There are still some logical error. Fix it yourself...
void sales_type(char& s_type, int& brand, int& quantity,int&
total_coke,int& total_pepsi,int& total_dry,int& total_hires){
s_type...
What is the error message?
Errors in your code:
=> Declared as BUFLAN and using as BUFLEN
=> Use sprintf, not sprint
Better use int main() and do a return 0 at the end, instead of void main
Axon, why not... provided you have to do mine :-) hahaha...
1. In your overloaded << operator do a "return out;"
2. In the function List::replace(VALUE_TYPE v), you are declaring a variable VALUE_TYPE x. Without initializing it to anything you are trying...
try this...
#include <iostream>
using namespace std;
void header();
void table();
Earlier code I have not compiled... This code is compiled successfully and it worked...
#include <iostream>
using namespace std;
int calculations()
{
int number;
int calculations()
{
int number;
int positiveValues;
int negativeValues;
for (int counter = 0; counter < 1; counter++)
{
positiveValues = 0;
negativeValues = 0;
Is it your requirement to use friend function? Else you can use this code...
#include <iostream>
using namespace std;
class List
you missed the starting parenthesis in the overloaded + operator defination
#include <iostream>
using namespace std;
const int CAPACITY=30;
class List
{
public:
typedef int VALUE_TYPE;