General C++ Programming - August 2016 (Page 10)

using || in do-while loop
 
I have this program here, it isn't complete, just starting it off. It's a switch sequence within a d...
[3 replies] Last: Here, given the way you are using the switch statement, you could do t... (by andywestken)
this program isn't working and i don't know why?
 
#include <cstdio> int main(){ int s=12; int c=0; int l=1; freopen("hallin.txt","r",stdin); ...
[2 replies] Last: Line 10, s-l; , is not doing anything. (by closed account z05DSL3A)
how can i read a gif file byte a byte?
 
heres what i know about the gif files: 1 - the 0x2C(',') is the Image Separator; 2 - the 0X3B(';')...
[1 reply] : Make sure you opened the file in binary mode. (by Peter87)
I need some assist here , my C++ code is not working
 
My code is as below , I cannot display anything out , I spent a whole day on checking the mistakes ,...
[4 replies] Last: I found out what's the problem already , thanks guys (by badbuddy1)
hello, I have a question about ctime library
 
I want to get the time difference between certain moments of objects life but it seems that variable...
[4 replies] Last: thank you very much!!! (by davidgoder)
Best Graphical Library To Develop a Weather Simulation Map?
 
I want to recreate a weather map that you see on most weather channels. I don't need real time Doppl...
[no replies]
Why pass by ref when you can pass by memory location?
 
Hi All, I have been playing around a little with the C++ references, and I wonder - why would you u...
[4 replies] Last: Thanks Ganado, So you would use this in the case of objects (rather ... (by nzsteve)
enums nested in a class
 
// forward declaration, doesn't work // enum Cage::Bird; class Cage { Cage::Bird f_bird; ...
[2 replies] Last: Thank you, Thomas! (by nuderobmonkey)
by well
less<TYPE>
 
template <typename T,typename F=less<T>> int compare(const T &v1,const T &v2,F f=F()) { } I ...
[1 reply] : F() - an anonymous temporary object of type F (which is value ini... (by JLBorges)
Rotate the Matrix
 
I'm trying to rotate a matrix inplace (clockwise direction). Below is my code, everything seems righ...
[2 replies] Last: @AbstractionAnon I get it thanks. Silly mistake (by atinesh229)
Unreal Engine Compiling Errors
 
I'm having trouble finding the problem compiling this in Unreal Engine 4 4.12. Can you tell me the p...
[no replies]
Forgot a few of my basics
 
Ok, I did cote code in c/c++ for about 6 or 7 months. Can you tell and explain the output of this co...
[9 replies] Last: That's crazy! Why is it so unorderly? What happened to order of opera... (by closed account E0p9LyTq)
by Bo Hu
read in .csv data and array manipulation
 
Hello, I tried to read a 3001 x 90 .csv data file into a two dimension array and then divide the ar...
[5 replies] Last: I tried to fix it as possible as I can, but I got lost again.... #i... (by Bo Hu)
need help with pizza c++ programm
 
Hi everybody ! i am a begginer c++ programmer and im trying to make a basic pizza programm that take...
[3 replies] Last: for (int i=0; i<c; i++) { total += prices[order ] * quanti... (by AbstractionAnon)
Unexpected side effects of using inside a namespace
 
Hi, I just came across the most unexpected situation and I want to share it with all of you just in...
[3 replies] Last: Yes I had included chrono. Yes JLBorges, you provide the rationale: X... (by JUAN DENT)
sorting algorithms process output! NEED HELP!
 
CAN ANYONE HELP ME CONVERT THIS CODE TO OUTPUT THE PROCESS OF INSERTION AND SELECTION SORT. SO THAT ...
[1 reply] : Do you mean like this? Enter no of elements :5 Enter array element... (by Thomas1965)
BIG O time calculation question
 
According to this book on discrete math, if O(x^2) is the complexity, and it takes 3 seconds to run ...
[3 replies] Last: The question is bogus in 2 important ways. First, Big-O is an uppe... (by htirwin)
member access operators
 
Hi, If I create an instance of obj (Wood obj) I can only access its members/vars with (.) -- cannot...
[3 replies] Last: Some lamo attempts to replicate the "non-syntactic" a->b == (a*).b (by technologist)
by Bo Hu
Issues with stack overflow and access violation reading location
 
Hello, everybody, I am totally a beginner in C++. I tried to write some codes for my study, but, by...
[1 reply] : LIne 302 creates a very big array on the stack. The stack is usually r... (by dhayden)
A program to check gift card balances?
 
So I work for a company who gifts people with different type of gift cards l, depending what the cus...
[6 replies] Last: Sounds like a straight forward process. You need to read the gift card... (by Thomas1965)
August 2016 Pages: 1... 89101112
  Archived months: [jul2016] [sep2016]

This is an archived page. To post a new message, go to the current page.