49,761 Topics
| |
Hi guys, I am having problems with a simple program I wrote, here's the source code: [CODE]//seventh #include <iostream> using std::cout; using std::cin; using std::endl; class Maths { public: void enterInstructions( int instructions ) { cout <<"I want to do a: \nAddition\nSubtraction\nType your choice here: "<< instructions << endl; } … | |
i want to give a presention on functions use in code and want to give a comparision by function call by value and by reference with different cods can any one help me ,as give me these codes? | |
Is it possible to convert a python script into a compileble langguage. ????? | |
I am a C programmer. I am working on a C++ code and translating it into C. I got stuck in a point where I do not understand what is going on. I would kindly ask if you would mine help me to understand these problems. I have three problems: … | |
when should i use "return 0;" at the end of a main() function? | |
Hello!! I have started learning c++ and it has been a real sucess until now. My codes that worked before and those that im trying to use now, doesn't work.. I get a compiler error... Here is the code and the error: // tutorialearning.cpp : Defines the entry point for … | |
I have debugged and dec2bin function outputs "bin" value is right, but cout function somehow prints out wrong value. How to fix it? Thanks! [CODE] #include <iostream> #define bit 5 void dec2bin (int, int *); int main (void) { int bin[bit]; int num = 24; // example dec2bin(num, bin); for … | |
Hi, I have this homework problem that I need some help on: In 3D: Given 2 links attached end to end with lengths L0 and L1 respectively, a point P0 that the first link starts at, and a point P1 that you want the end of the 2nd link to … | |
Hi guys, I have two bushes to clear up. I have doe SQL fro some time now but I have never done blob. I think the next project will require it. So here are my Question: 1. How blob differ from any other type like text? 2. How to create … | |
help i need to search and delete a node from a link list but i am not sure of the algorithm can someone please help me with the algorithm and concept need example thanks.. | |
This code is a tutorial, from internet, I can make it to compile, error to advance for me, (+) use is a ???? for me, using MV C++. Is a class tutorial..... [code] #include<iostream> #include<iomanip> #include<string> using namespace std; class Food { private: //instance variable.Every object wiil have this variables..... … | |
Well, i'm developing a program, ( API ) and i'd like to use a [url=http://www.snap2objects.com/wp-content/uploads/2009/10/6.jpg]non standar font,[/url] for some section of my program. My question is, how can i do this, i mean, i supose i have to install the font on the user pc, but how do i do … | |
Hi, I am writing a simple program, trying to learn the usage of map. Following is the data, I will be storing in a map and I get a core dump when line No: 54 is being executed. Please let me know if something is wrong in my code. I … | |
I am having a hard time getting started on this array. I am in a C++ class but I have no refrence material to go off of This is what i have so far, The purpose of the code is to find out how many wait staff is needed if … | |
I am converting a console IO program to a file IO program. The program worked perfectly as a console IO. I thought I made the appropriate changes to the program. It compiles, and when I run it output does go to my output text file, but the output is the … | |
Hi guys I use the following code to check if a user has specified a certain argument: [CODE]if (strcmp(argv[i], "-i") == 0) { // do something }[/CODE] I use the following code to check whether any arguments have been specified (e.g. -i test1) but it gives me a segemtation fault … | |
i am trying to make a program where a user inputs two numbers. the first number needs to be less then the second. then the program needs to add all the numbers together that fall between those two numbers including the two numbers. for example number1 = 1, number 2= … | |
I need to find how long it takes to execute a bunch of code. I've tried using clock() but it's just not accurate enough for the small functions (it says 0 cycles have passed). I heard of gprof but that only seems to be for Linux. The version of Visual … | |
Hello, I'm trying to print out on the screen the the sum of a perfect number, and i can't quite figure it out how to code it. For example I now 6 is a perfect number so i need [ 6= 1+2+3 ] to print out on the screen. Any … | |
Hi, I'm trying to convert a void pointer to a struct pointer.. that's seems very easy but my compiler give me error. Thanks. /home/subi/Personal/Projects/LinkedListUserInfo/main.cpp||In function ‘error_t parse_opt(int, char*, argp_state*)’:| /home/subi/Personal/Projects/LinkedListUserInfo/main.cpp|50|error: expected primary-expression before ‘)’ token| /home/subi/Personal/Projects/LinkedListUserInfo/main.cpp|50|error: expected ‘;’ before ‘null_pointer’| /home/subi/Personal/Projects/LinkedListUserInfo/main.cpp|48|warning: unused variable ‘null_pointer’| ||=== Build finished: 2 errors, 1 … | |
I am after making my program wait before responding to the users input, what code do i use for this and how do i implement it? [CODE]#include <iostream> using namespace std; int main() { char instuctions = 0; int A = 0; // user input 1 int B = 0; … | |
Problem: Use a 2 dimensional static array with 3 rows & 2 columns to the course number and number grade you have received in that course. The program should have three functions called get information, printinformation, and convert. You need to send array to getinformation and printinformation functions as parameters. … | |
Is there any advantage in declaring a variable local to a function const? i.e., I want to use a sine value a couple of times so I store it in a local variable. If I make it const does this facilitate any compiler optimizations... or anything beneficial? [CODE] double my_func(double … | |
Hi! I am trying to convert my c/c++ code into a python module. The code captures an image which it then runs some algorithms upon. For a start, I am trying to write a code that just captures an image. I am using opencv for the image capture (in the … | |
As the title states, I'm trying to learn how to create a custom GUI window for Windows. Basically I'm asking how I can output pixels to the screen without using any of the default windows gui classes. | |
Hey everyone, I want to start learning socket programming. Ay references and advices will be greatly appreciated!! | |
I'm working on my first game in C++ and SDL. The game compiles and runs perfectly on both my boxes (Arch Linux and Windows XP). When two of my friends were to test the game, one of them (running Windows Vista) said his machine BSoD'd every time he ran the … | |
Dear all, I am currently working on a mini-application using Visual C++, and it goes pretty much like this: The program, using mousehook, will retrieve the coordinates of the current mouse position using getcursorpos when a right click is executed, and it will return with a red dot on the … | |
I got a problem solving this. I tried to use the sample input and I got exactly the same output as the sample output but I still got WA. Even my output had the same format and same number of characters including every new line but still got "wrong answer". … | |
| My program is able to create the folder fine but I wanted to know if there is a way to put the date and time in the title? C++ and using Visual Studio 2008 for Windows. [CODE]system("mkdir %SYSTEMDRIVE%\\Blebble\\Blabble");[/CODE] |
The End.