General C++ Programming - December 2018 (Page 5)

by Satan
How much ram the computer is using etc.
 
How can I check things like how much ram the computer system is using in total currently (not just for the program), how much space is in drive and how much ram...
[5 replies] Last: do you want this inside your program or for your own information? It... (by jonnin)
Parse raw data fast with specific format
 
I am searching ways to read a text file fast, really fast. I have thought of many solution but could not reach to an optimal one. Let me describe my problem and...
[6 replies] Last: In _PART_1_, There are two columns, ID and NAME Is that a numeric ID... (by dhayden)
function executed before main
 
following is what I wrote #include <bits/stdc++.h> using namespace std; int sum(int arr ) { int k,d=0; cout<<"function called"; int z=89; retur...
[5 replies] Last: int z=sizeof(are)/sizeof(are ); If your planning to move this inside... (by dhayden)
Pointer declare (1,2)
 
#include <iostream> using namespace std; int main () { int firstvalue = 5, secondvalue = 15; int * p1, * p2; p1 = &firstvalue; // p1 = address of firs...
[31 replies] Last: You can start with these: https://isocpp.org/wiki/faq/const-correctnes... (by keskiverto)
Finding yearly interest out of compound interest
 
When I try to find out my yearly interest, I get the wrong answer. The first year calculation works just fine but for the next year interest doesn't print out t...
[1 reply] : Use [co de] tags when you post code (it's the <> format icon on the ... (by salem c)
C++ Homework
 
Hi, I just need help doing my homework, I just started this class, but these questions seem advanced... I don't understand.. can someone take a look? I dont...
[1 reply] : Well you don't seem to have made much progress in the past two weeks. ... (by salem c)
by Meks
String Selection Sort Modification
 
String Selection Sort Modification Write a program that uses the selection sort to sort the names found in the presidents.txt file. Have the program prompt ...
[2 replies] Last: Please, review the link below: https://stackoverflow.com/help/how-to-a... (by chicofeo)
Simple Plane Game
 
Hey Guys, I want to make game like this, https://thumbs.gfycat.com/DelightfulEquatorialGibbon.webp But I have some difficult problem in my code. 1)How c...
[no replies]
Getting variables from and calculate on it c++
 
Hi, I need to develop a calculator which reads the input as shown below from a text file and calculate the expression given by the user. Input: i = 1 ...
[9 replies] Last: So I may aswell explain while it's relatively fresh in my head(been ab... (by adam2016)
by Raj12
Reference Variable
 
Can a reference variable change to refer another variable? Theoretically I red its not possible but in my test program it is not throwing any errors while ch...
[2 replies] Last: Sorry I found error in my code. some one can delete this thread if pos... (by Raj12)
How do I make my auto clicker randomize the ms it clicks at?
 
How do I make my auto clicker randomize the ms it clicks at? Please provide me the code. Code: #include "stdafx.h" #include <windows.h> #include <iostream> u...
[1 reply] : Use std::uniform_int_distribution (by mbozzi)
Looking for a pattern(s) for attaching a Table to an arbitrary C++ struct
 
Hi, I have the following challenge for which I would truly appreciate some pointers. Basically I want to write a connector from a C++ struct to a DataTable w...
[14 replies] Last: Finished! I came up with 2 grid displayers (one where all of your colu... (by JUAN DENT)
C++ Traffic Jam Issue
 
Hey guys, could you please help me on this one? I really appreciated the help I received yesterday regarding the homework about the dates. Here are the instruc...
[8 replies] Last: That's progress. I'd use Array instead of *(Array+index) because ... (by dhayden)
Macro function doesn't calculate as it should
 
Hi guys, I made macro function which converts kilometers into meters. Logic Works but practice does not. I get weird number. Code is below: #define one_km 10...
[18 replies] Last: Yeah, that's a good point. I've probably only done it once or twice to... (by Ganado)
Reading files from a directory
 
I've written a program which takes one file after the other as input and process them and send the result to an output file. But now I'm getting weird situation...
[1 reply] : I have no idea. A couple of things. First, please use code tags. On... (by doug4)
by onkar
cab program
 
I'm creating a c++ program on cab programming and I need some help . I've done half the program till the point that I've put in the details for the fare and stu...
[1 reply] : class golacabs This makes no sense. It looks like you're trying to ... (by Repeater)
... about threading
 
hi everyone, i plan to make a little game/simulation that makes use of 2 threads: 1. main thread, responding to input and render graphics 2. a spawned sub-thre...
[2 replies] Last: i think that should world as intended ... (if i dont miss anything?) ... (by John87Connor)
Changing normal pointers to smart pointers
 
Hi, I want to change all my pointers into unique pointers so once it passes out of scope all the pointers will be deleted and clears up memory space how can I c...
[15 replies] Last: Using the same node structure as in the original code, but replacing ... (by JLBorges)
how to make the calculator program loop after an unrecognized symbol is inputted
 
I have a problem that I would like to fix. I wrote a program to take in an expression in infix notation and all the mathematical operations work, and if an unre...
[3 replies] Last: Perhaps if your main wasn't so bloated, you could create a decent prog... (by salem c)
Impossible to represent 1.001 as a double?
 
Hi all, If I assign 1.001L to a double, then inspect it with the debugger, it has a value 1.00099999999 Similarly if I sscanf a string of "1.001" with for...
[12 replies] Last: In my application I am receiving a number "1.001" represented as a s... (by TheIdeasMan)
December 2018 Pages: 1... 34567... 10
  Archived months: [nov2018] [jan2019]

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