thank you babkockdood. Is that the result you got from it? I think I figured it out though. if i put:
system ("PAUSE"); before the return 0; in the default would it wait to display the code?
Type: Posts; User: dyelax
thank you babkockdood. Is that the result you got from it? I think I figured it out though. if i put:
system ("PAUSE"); before the return 0; in the default would it wait to display the code?
im using microsoft visual c++ 2008 and when i build it it says there are no errors and when i want to run it there are 2 options: start debugging and start without debugging. if i start without...
alright so theres nothing wrong with the end part but what could be the reason that it crashes in the default of the switch cases before it displays the text? as i said before i tried putting in...
its not an error. it compiles perfectly and runs perfectly if i dont debug but if i try to debug it quits out early right before the end and also it quits out in the default on the switch cases...
Please help
hey so i posted my quiz up here for help a while ago and it was working perfectly when i clicked run without debugging... untill i tried to run it with debugging. when i do that it crashes right...
sdjkla;;jfbslak;djf. I always screw that up. thank you nvoigt.
ah I think I figured it out. the program had a separate c file in it with a hello world program... who knows how that got there...
i also have another problem with this code. I'm trying to make a...
are you sure you're writing it in a .cpp file? because from the errors it looks like you're in a .c file which is for programming c not c++. im not completely sure thats it (im a "newb" too) but...
im getting an error message in this simple program im practicing functions with that says "Command /Developer/usr/bin/g++-4.2 failed with exit code 1" and i have no idea whats causing it. heres my...
alright so I've been using Microsoft visual studio ti do my programming so far but I just recently got a mac and I installed xcode on it so I could program. Only i cant even figure out how to open up...
alright so i have almost no idea what you guys are talking about. I've been learning off the tutorials on this site but it looks as though they haven't included a lot of stuff. how would you guys...
memloop: whats the string class? I'm using #include <cstring>
iMalc: would changing my structure to that make the example work or would I have to change it further? and whats up with the...
alright so im making a program to practice strings, pointers and structures. Its a structure that holds information about the members of my band and I want it to output the instrument and gender as a...
Thanks! program works beautifully now
ok. could you give me an example of how i would do both of those things?
also as I've already declared my array like this its saying I'm redefining it by doing that^
int ar [8];
for (int i = 0; i < 8; i++) {
ar[0] = bro;
ar[1] = jock;
ar[2] = art;
alright Elysia im taking your advice and im doing something wrong haha. heres the code:
#include <algorithm>
foreward_iterator max_element (foreward_iterator start, foreward_iterator end);...
sorry for bringing back this thread but i gave up on this program for a little. I really dont understand how i would make a max variable or even implement it in here
so for mine would I do something like variables[0] = bro, variables[1] = jock etc? and i still dont get the whole max variable thing
ok thanks a lot. I do have a couple questions though cuz i kinda suck at programming haha. in the 3rd line of your code what does that value do? In the example on this site the value there is x*y but...
Hey guys, so I just recently got back into programming and I decided to program one of those stupid "what highschool stereotype are you" quizzes to see what i still remember. Everything went great...
ok wow im having a lot of problems with this code. i tried what you said to initialize it but im getting 3 errors:
error C2057: expected constant expression
error C2466: cannot allocate an...
ok thank you that helps a lot. also a completely unrelated question: what does <<endl; do?
so how would i go about initializing this? and should i just make a for() statement for each case?