49,757 Topics
| |
I am fairly new to C++. I work as an intern and I need to pass a pointer to a function. Can someone please help. [CODE]U8 System::check() { Array drives = Array::update(system); ...... ...... check2(drives); ........ } U8 System::check2(Array drives) { Array bad_drives = Array::drives.filter(&new_drives); }[/CODE] If I were to … | |
Hi guys i want create a program that can write to a pdf file and here is the code i used. when i run the program, it compiles well, and runs but the pdf file that is created is not readable/corrupt. i am just wondering whether there is some library … | |
i hv made it sorry for the disturbance | |
[B]Hi guys!!... I am just looking for some startup guidance with a program I am supposed to write.. it goes like this ->[/B] A program which compares these three hashing methods: 1) open addressing with linear probing, 2) open addressing with quadratic probing, and 3) separate chaining. Input will come … | |
I am using a) Linux b) Pthreads I want to write a program, with two pthreads, to cater for two queues of people. People arrive at each queue at a random interval of 1 - 10 seconds. Each time a person arrives, print out the number of people in each … | |
Overview: I am trying to write a program that generates an array of randomly generated integers, and sorts them as the array is being generated. I've just used 7 elements in the following example, as it's easier to check for errors that way. Code: [CODE]#include <iostream> #include <ctime> #include <cstdlib> … | |
Hey, I know the algorithm for a network router but do not know how to implement in coding.Kindly help me with the coding part. Regards. | |
hi.. i am using windows 7 (32 bit) ultimate. where can i get turbo c++ for windows 7?? what should i use for compiling and running c/c++ programming in windows 7 | |
Ok, so im trying to make my sister a flashcards program with dev c++. What you do is put in the deck name and how many cards you want. Then you go through for each card and put in what's on the front and back. I also want it so … | |
Hello, I have got an square image with a point specified by the user(not neccessary to be in the centre). I want my program to draw a line or vector from that point to the boundary of the image. Then, I want to draw the same vector again and again … | |
Hi, I can not create executable code by using a makefile.How can I generate the executable code.I wrote this lines into my makefile and in the terminal I wrote make but I can not do it.Please help me. myprog : myprog.o mylibrary.o gcc myprog.o mylibrary.o -o myprog myprog.o : myprog.c … | |
I am taking this class through devry and that is my assignment for week four and this is my second attempt at the class..but this is what i got for this assignment..program compiles properly and runs...with no errors..got it from code snippet stealing from other classmates lol [code]# include <iostream> … | |
In the main function, I have one two-dimensional array, A. I need to pass A into a function f, which takes A, may change A. f will also generate another two-dimensional array B based on some operations on A and return A. I know it is about passing pointer passing … | |
Hello, I am a student and I'm having trouble figuring out why my if statement won't evaluate. I'm not getting any error in my compiler - I'm using Dev-C++ 4.9.9.2 The if statement in question is on line #160 in the code below (full code). You will need the students.txt … | |
Hello, I would like to have a program that solves Gaussian elimination. I need it for reference, I think it would be nice to have a tool like this. Now, I know there are many codes I could use online, but I need a code that formats my equation. Like, … | |
In this program i am trying to find numbers that are multiples of 7,11, or 13, also if the total of the numbers is even or odd also the square root value of each number also if there are any prime numbers in the list [CODE]#include<iostream> #include<iomanip> #include<fstream> #include<cmath> #include<conio.h> … | |
Hi, I am starting to make programs with GUI, so with buttons, frames etc, and some of them will work via internet, like multyplayer card game or something like that. So during my search, I ran onto few choices, Qt, Win32 api, wxWidget and by most forums the Qt is … | |
Hi I'm new to C++ and I'd like to make a program that responds to MIDI input from an external device (e.g. MIDI keyboard). I've found a library that should do what I want here: [URL="http://www.music.mcgill.ca/~gary/rtmidi/index.html"]http://www.music.mcgill.ca/~gary/rtmidi/index.htm[/URL]. I'm using VC++ 2010 Express, and I can't figure out how to actually use … | |
For this code i am inputing one number and trying to see if it is a perfect number [CODE]#include<iostream> #include<cmath> #include<iomanip> #include<conio.h> using namespace std; void perfect(int); int isfactor(int, int); int N, i; int main() { perfect(N); isfactor(N, i); } int isfactor(int number, int divisor) { if(number%divisor==0) return 1; else … | |
Hey everyone :) I'm new to c++ and have just joined this site. Looks great. Hope you guys can help. I'm having trouble with the function calcAllowedPerChild() What I want the function to do: subtract the gifts TOOTHBRUSH, HIGHLIGHTERS, CRAYONS, NOTEBOOK , AND PEN, from the amount left(leftToSpend) while the … | |
Hello If we want to do a program for this restaurant but we dont know how many menu items and we know that is it less than 50 also we want to count every single item seperately when the user choose that item, and then compute the price of the … | |
Write a program that allows the user to enter a series of positive integers one at a time and in increasing order (using -1 as a sentinel value), and then computes and displays the median value of the data entered, as well as the number of data values entered. You’ll … | |
Hi, I'm working on my time complexity understanding in C++. Right now, I'm trying to figure it out, and kinda got some of them, such as: constant O(1): [CODE] int first(int N){ int i = N; int x = 0; x++; return x; } [/CODE] O(n) [CODE]int second(int N){ int … | |
Hey guys, I'm reading this thing about "Time Complexities". But I'm having a hard time wrapping my mind around it. I know that it's all about the different algorithms that take different amounts of time for different amounts of instructions and stuff. What I don's understand is that how to … | |
Here the value of int x is always zero. I don't know if there is any case where it is non-zero. If so pls reply. [CODE]int OperOverld::operator--(int x) { cout<<x<<endl; //always zero //some code goes here //... //... //... //atlast return some int }[/CODE] | |
hello everyone. i am making a program which has multiple windows. how do I program that when one window pops-up, the other closes? i am using Microsoft visual studio 2010, in a Win32 application. i am not using a windows form. | |
I cannot figure out how to open the results/output window in Dev c++. Also how to effectively use step over / step into . I kept breakpoints at certain points in my program but step over from then onwards does not happen by pressing ctrl+f7 and I dont know how … | |
Hi, I've been looking for a while for things that would give me random numbers under a value that I can specify (for me it's 5). I've seen [ICODE]rand();[/ICODE] and [ICODE]srand();[/ICODE]. I also know that[ICODE]srand()[/ICODE] is the seed and [ICODE]rand()[/ICODE] is the random number itself. Even the example programs don't … | |
hello. I am struggling until 4 weeks. you know ancientDragon. whatever . ı do no go forward anymore. I need names of books that can help me. I have a information but it is not enough. ı want to understand questions on these websites. I have only little array, pointer, … | |
hello every one i am making a program what requires that the user types in some text in a textbox. the problem is, how do i get that text from the textbox into the std::string (or a other kind of string)? i don't know how to do that in Win32, … |
The End.