49,761 Topics

Member Avatar for
Member Avatar for coolbeanbob

Hello All, Not sure this is the right forum, but I have a Visual Studio question. I am used to using code::blocks as an IDE. My current instructor likes to use Visual Studio 2008, so I am trying to adjust. One big difference I have found is that when a …

Member Avatar for coolbeanbob
0
262
Member Avatar for wfws

I'm a C++ student, and I'm almost there on this assignment, except I can't get the search function to work correctly. The search function should accept a search input from the user, then list all the items related to that input. In this case, its all the tasks related to …

Member Avatar for NicAx64
0
142
Member Avatar for PSP1202

Hey all, I'm fairly new to C++ and am trying to write a program that continues asking the user for a number until "0" is entered. I am supposed to count the number of positive, negative, odd, and even numbers that the user has entered once the program is terminated(0 …

Member Avatar for MandrewP
0
421
Member Avatar for minghags

Hello! Im writing a program that outputs some triangles and such. And I want to count the written *s. If anyone would help i would really appreciate it. Code: [CODE]#include <iostream> #include <string> using namespace std; int main() { char znak; znak = '*'; int st_vrst = 0; int ploscina_trikotnika, …

Member Avatar for WaltP
0
110
Member Avatar for stereomatching

I am a newbie who just graduated. I found my first job and begin to review some legacy codes And I find out there are a lot of macros which could be replaced by function (somebody especially c coders may think macro is a better choice) Not even that, I …

Member Avatar for stereomatching
0
249
Member Avatar for iamthesgt

In writing a logging program for a SDK Engine, I have come across some problems. The logging function works fine when called with test programs, but when I run it in a full test of the SDK Engine, no file is ever created. I added some testing lines to make …

Member Avatar for iamthesgt
0
398
Member Avatar for karmstrong

Please take a look at the following code. When I do not put my pointers in an array the code works. See the commented out section. I thought it would be nice to do an array as I could then have more control over my output. I could also add …

Member Avatar for MonsieurPointer
0
137
Member Avatar for Ravic85

I'm having a bit of trouble figuring out what i'm doing wrong with my overloaded operators Header file [CODE]#ifndef SavingsAccount_H #define SavingsAccount_H #include <string> using namespace std; class SavingsAccount { friend istream &operator >>(istream& input, SavingsAccount & ); friend ostream &operator <<(ostream& output, const SavingsAccount & ); public: SavingsAccount(); SavingsAccount(string, …

Member Avatar for Ravic85
0
1K
Member Avatar for jeevsmyd

I'm new to generic programming and I just cant figure out what is wrong in this . The program is supposed to make a linked list using class. I have used 2 classes so that a single object of class LL can be used to manipulate a linked list . …

Member Avatar for mike_2000_17
0
131
Member Avatar for bkpally263

Hey all I need to convert audio file of wav format into text file in order to feed it as input to an encryption algorithm(IBE encrypt method of [URL="http://www.shamus.ie/"]Miracl[/URL] library takes only texts as input) and have to reconvert the decrypted text file to audio format. Could you please suggest …

Member Avatar for sujoy chatterje
0
1K
Member Avatar for Mopikope

I am having a problem with trying to copy a "char array to an int array". I have a code to randomly picked an amount of character and (in progress) print out how many occurrences, even if it's not in there a letter has. For now I'm only doing upper …

Member Avatar for Mopikope
0
117
Member Avatar for Zssffssz

Well I noticed recently that the more unusual bool operators arnt there. How would I use them? Ex: xand, NAND, nor, etc.

Member Avatar for mike_2000_17
0
101
Member Avatar for cvanithakpm

plz help me to know..whether this pointer in c++ is public access or private access

Member Avatar for gerard4143
0
114
Member Avatar for maybnxtseasn

[CODE]struct ch8_struct { int field1; short field2; char field3; int field4; double field5; }; struct ch8_struct g_StructArray[3]; ch8_struct *g_pStructArray = g_StructArray; ch8_struct **g_ppStructArray = &g_pStructArray; g_ppStructArray[1]->field1 = 11;[/CODE] program is crashing on g_ppStructArray[1]->field1 = 11; i think my pointer notation is wrong :)

Member Avatar for Caligulaminus
0
74
Member Avatar for cypherscouter13

I'm getting the error for the following code "error C2664: 'KaibaMainPhase' : cannot convert parameter 1 from 'void (__cdecl *[2])(std::vector<_Ty> &,std::vector<_Ty> &,std::vector<std::vector<_Ty>> &,std::vector<_Ty> &,std::vector<_Ty> &)' to 'void (__cdecl *)(std::vector<_Ty> &,std::vector<Card> &,std::vector<Card> &)" [CODE]class Card { public: string GetName() {return Name;} void SetName(const string& setName) {Name = setName; } void SetType(const …

Member Avatar for cypherscouter13
0
209
Member Avatar for Abiha

Problem: our program is syntax-wise correct, the problem is that it is not evaluating power operation for alphabets, can anyone help it is urgent a+b*c/d^e also tell the output for this expression #include<iostream.h> #include<conio.h> #include<string.h> #include<stdio.h> #include<ctype.h> #include<math.h> #define MAX 20 char stack[MAX]; int top=-1; char pop(); void push(int val); …

Member Avatar for ezaiza
0
258
Member Avatar for Anas Shahid

[code] # include<stdio.h> # include<stdio.h> # include<process.h> # include<stdlib.h> # include<ctype.h> # include<conio.h> # include<mem.h> unsigned char huge Data[100001]; unsigned char keystream[1001]; int Rpoint[300]; void main(int argc,char *argv[]){ FILE *fd; int i,j; int size; char ch; char *name; int cracked; int sizemask; int maxr; int rsz; int pos; int Rall[300]; …

Member Avatar for WaltP
0
233
Member Avatar for sohar11

Hello everyone.. I have char of an array I need to stop reading from the array if I reache to newline.. the array cosists of characters of a text file but I need to stop reading when I reache to first \n or endl.. I tried to use this while(code[i]!='\n'){ …

Member Avatar for WaltP
0
100
Member Avatar for ankit.4aug

is there is any way to access 3rd element of a linked list without using arrow operator??

Member Avatar for ankit.4aug
0
219
Member Avatar for MandrewP

I'm trying to do disk reads and writes when programming in C++ in the win32 console mode. I can create the file on disk using CreateFile(), but I can't figure out how to read or write to that file. I used the ReadFile() and WriteFile() functions but I just get …

Member Avatar for MandrewP
0
354
Member Avatar for TheFearful

Hey, guys. I'm new to this forum and this is my first post ever on this site. I am currently a freshman in Penn State University and I am having trouble with my C++ class. I have a group project but have no idea where to start with this program …

Member Avatar for TheFearful
0
461
Member Avatar for Zvjezdan23

This is code for the slope intercept formula y = mx + b I am supposed to find the slope (y2 - y1) / (x2 - x1) and have the user input the b for the y = mx + b in my program. Once the user does that I …

Member Avatar for Zvjezdan23
0
2K
Member Avatar for rugged1529

Hello I'm trying to figure how can I just a while or what statement to either stop at the next delimiters or stop at the end of the line. here's my code: [CODE] while( getline(i_file, arrayl, ';')){ cout<<"check 1"<<endl; istringstream iss(arrayl); iss>>array; cout<<array<<"<~~~~~~~~~~~array!"<<endl; int num [array]; int i = 0; …

Member Avatar for WaltP
0
126
Member Avatar for giora88

Hello. Is there a way to move to the mouse cursor on the screen using C or C++? I am using windows vista and Microsoft visual studio 2008. I am pretty new to C so I don't know much. I have read previous threads which said that you need to …

Member Avatar for Narue
0
262
Member Avatar for ToweyLeake

When I run my program it prints out the number for the forty eighth sequence as being -132375223 when it should read 4807526976. What am I doing wrong? -Towey [code] # include <iostream> using namespace std; int main () { int x1=0; int x2=1; int fib; for (int i = …

Member Avatar for ToweyLeake
0
113
Member Avatar for sasho648

I'm writing a Level Editor but my program is shows the X,Y,Z positions like DWORD(unsigned long). I want to show them like a float but I can't find a formula or function for that. If you know something please reply!

Member Avatar for sasho648
0
324
Member Avatar for CalebS

I've looked into all the other threads and I am still lost. [CODE]#include<iostream> #include<cmath> using namespace std; //Prototype's ////////////////////////////// double functiony(double); double area(int, double, double); // Main ////////////////////////////// int main (void) { //Solving for y=x^3 using k as y and d as x double k; double d=0; k = functiony(d); …

Member Avatar for mike_2000_17
0
165
Member Avatar for stereomatching

[code] void test(std:shared_ptr<some_type> A) {.....} [/code] would make a copy of a shared_ptr what if we pass a shared_ptr into a function like [code] void test(std:shared_ptr<some_type> const &A) {.....} [/code] Is this safe? Thanks a lot

Member Avatar for stereomatching
0
187
Member Avatar for Zssffssz

When on the digital mars website he advertzed that their compiler could use all 80bits of a 32bit machine. What the heck does this mean?

Member Avatar for Narue
0
62
Member Avatar for speak1

So I need to do this following program and I'm totally confused at the moment. Can someone please help me? Your help will be greatly appreciated. Objective: 1. Write a program that incorporates function modules 2. Use appropriate function declarations 3. Use function headers and write function procedure 4. Use …

Member Avatar for Zssffssz
0
460

The End.