49,761 Topics
| |
These are codes that do absolutley nothing, except to show whart you can do with to much time on your hands. Oh the silliness | |
Here I have some code that will run a program that generates a bunch of lowercase and uppercase letters from length 15-25 and will swap it first using an iterative swap method. It will then generate a second set of letters and will swap it this time with a recursive … | |
Hi Everyone, I need to know how can we represent the projectile motion gven a certain angle and velocity, such that I can watch the animated ball moving in is path on screen.... all using openGL in C++ | |
Hi Can any one explain how we use CListCntrl class in mfc to track the listby using dialog based application..just simple example.. thanks in advance.. | |
ok so i am new to programing and need to make a program that adds and subtracts two coordinates this is the main file #include <iostream> #include "Coordinate.h" using namespace std; int main() { Coordinate a( 1, 7, 0 ), b( 9, 8, 7 ), c; a.printCoordinate(); cout << " … | |
I am having trouble wrapping my head around classes. I'm not to sure what they are used for or how to use them. so i need some serious help with this assignment for my class. This is the assignment: **Create a class called Coordinate for performing arithmetic with x/y/z coordinates … | |
ok so as a homework assignment I have to sort a c-string array alphabetically. We have to use pointers and cannot using strings (although strcopy and strcmp can be used). I can sort integers and strings but for the life of me cannot figure this out. I'm pretty sure i'm … | |
**Hello Everyone! Please Help me on my C++ Program it's kinda buggy and full of errors. I hope someone can help me~ Thanks in Advance! :D** #include <iostream> using namespace std; int main() { int stun; float NUO, APU, IA, DP, Bal; cout<<"Student Record\n\n"; cout << "Student Number: "; cin … | |
. What wrong with the following code segment? int* = needle; needle = new int; *needle 100; cout << *needle; needle = new int; *needle = 32; cout << *needle; | |
What wrong with the following code segment? int* birdDog; int* germanShortHair; birdDog = new int; germanShortHair = birdDog; *birdDog = 42; cout << *birdDog; delete birdDog; cout << *germanShortHair; | |
I copied book1.xls into IISServer c:/inetpup/wwwroot objConn.Open "Driver={Microsoft Excel Driver (*.xls)};DriverId=790;DBQ=" & Server.mappath("/book1.xls") &";ReadOnly= true ; UID=admin;" Dim strSQL excelfilename = "Book1.xls" strSQL = "select * from " & excelfilename Dim objRS Set objRS = Server.CreateObject ("ADODB.RecordSet") objRS.Open strSQL, objConn,3,3 When I execute the page Error Type: Microsoft OLE DB … | |
I've installed the boost libraries binary version. How do I link this to my project? I've put the boost/bin path in my 'Path' environmental varialbe. Thanks | |
Hello I'm new to C++ and am trying my best to learn the language. Could someone please let me know why my program is not working. I have a feeling that I'm not passing values to and from functions. The program compiles and runs, but it just gives me a … | |
In my function definitions under apply_discount, when I enter a 1 or 2 for the discountQues to see if the customer has a coupon, the program thinks I'm entering a ticket type (1=toddler, 2=junior, 3=senior). Can you tell me what I'm doing wrong? I already tried making discountQues a global … | |
What does the following code do? int number; int& atlas = number; number = 212; atlas++; | |
can anyone tell me where is my problem ??? i cannot debug this program. -------------------------------------------------------------------- #include<iostream> #include<string> using namespace std; class student { private : string name; int id; float cgpa; public : void setName(string na); void setID(int number); void setCGPA(float result); string getName(); int getID(); float getCGPA(); void display(); … | |
I am suppose to write a program that inserts 25 random integers from 0 to 100 in order in a linked list. The program should calculate the sum of the elements and the floating-point average of the elements. I have been stuck with the add and average functions for some … | |
hi.i have a big problem .i just learn about classes and i don't know too much.now i have to do a problem using classes but for strings.i have to do one class string and do : -create a string -display the lenght of string -comparison lexicographics of 2 strings -concatenation … | |
I'm using winapi function GetTickCount() with delta time and I'm calculating the displacement of an object on screen like this: number_Of_Pixels_To_Move_On_Screen = (speed*delta_Time)/number_Of_Pixels_Per_Milllisecond but I get uneven movement.Sometimes it moves a litle faster ,sometimes slower . Can someone tell me how to get the object to move at a constant … | |
std::string s = "65//3"; std::istringstream indexBlock(s); for (int i = 0; i < 2; i++) { int index = 0; indexBlock >> index; std::cout << index << std::endl; } I would expect the output of the cout to be: output: 65 3 as I thought the stream iterates through the … | |
Hi Sir Referance to the previous article "C++ Help With Smallest Denominations of Coin Change" you suggested to use the code " CoinChanger::CoinChanger() ". And when I use it , it appear the error message " expected function body after function declarator" so could you please advise me regarding this … | |
Hello, I have some problems with this code //Selection and Bubble are working #include <iostream> #include <cstdlib> #include <cassert> #include <ctime> #include "Sorts.h" using namespace std; typedef void (*SortFunction)(int a[], int n); int main(int argc, char *argv[]) { if(argc < 4) { cerr << "Usage: " << argv[0] << " … | |
Dear friends, I want to create a program that reads 10 numbers from the user and store it in a file namely Numbers.txt. After that I have to read each numbers and if it is a Even number then it should be stored in a file "Even.txt" otherwise it should … | |
| How to print a sentence (including white spaces) from a file ? Or How to print entire text file which has a paragraph? I have tried a lot and the final programs is shown below.. but it can't print sentences exceeding certain length... it shows unwanted ASCII characters :( How … |
Hi, I have used xerces for xml parsing and it was working fine. But recently (i didn't change any coding) the same code doesn't work and it crashs the application after executing the XMLDomParser::parse() --> fatalError() method. It gives an runtime error exception: xercesc_3_1::XMLErrs::Codes at memory location xxx. For a … | |
I am very new to programming language and need help urgently. I am running a program which gives me one output file for every 5 min simulation. i have to copy and rename the output file in each step so that they can be used in another program . Any … | |
hi i have two question? if i wanted to read in file also, how do i do that? #include <conio.h> #include <iostream> #include <cstring> #include <ctype.h> #include <string> using namespace std; using std::string; enum CardType{ MasterCard, BankCard, Visa, AmericanExpress, Discover, DinersClub, JCB }; bool Validate(CardType cardType, string cardNumber){ int number[16], … | |
I'm sort of a begginer in classes. I must implement a simple problem: chosing a phone. I thought that I should make a program in which a user can select some conditions, like must have wifi or not, android or other, etc. and return a list with the phones that … | |
Hello! How is everyone? I know this program is somewhat simple, but I am working on learning classes, and I am trying to implement this in my code. I pretty sure my mathematics done in the program are correct, or at least on the write track. Here's what I am … |
The End.