Beginners - January 2015 (Page 6)

by PopEye
[QUESTION] DMA Deletion
Hello community. I was writing a simple times table project that creates a table object that gets created and then deleted with every iteration within a for loo...
Jan 28, 2015 at 5:35pm
[2 replies] Last: Amazing; thank you for the clarification. (by PopEye)
Help C++ Steering
I am having trouble figuring out how to even start calculating a steering vector by hand to help review the vector. That the first part which would lead into th...
Jan 28, 2015 at 5:13pm
[no replies]
Overwriting data from text file
Hello guys.. I am very new to programming and i just learnt about text file a week ago.. im doing a mini project for my school work... and im trying to overwr...
Jan 28, 2015 at 3:48pm
[1 reply] : You designate how to treat the existing data in the file when you set ... (by Computergeek01)
Same algorithm, different precision. Why?
In an exercise about floats, I was asked to compile the following algorithm: float a = 1.0; int b = 3; float c = a/b; float d = (c * b) - 1.0; cout ...
Jan 28, 2015 at 3:08pm
[4 replies] Last: > In my example (write 1), since I used intermediate steps, > some va... (by JLBorges)
solved
done
Jan 28, 2015 at 2:25pm
[1 reply] : In general, if you want to avoid having two different values mapped to... (by beko)
by kiri
had declared the decimals as doubles
What does that mean? " If you had declared the decimals as doubles your values would have been correct "I declared a const that was a decimal, but it should be ...
Jan 28, 2015 at 1:45pm
[2 replies] Last: Thanks. Jaybob (by kiri)
by beko
Assigning value to a char* in a function
This code makes my program crash: void copy(char* cp, int n) { for(int i=0; i < n; ++i) { *(cp + i) = data ; } } I'm trying to implement...
Jan 28, 2015 at 1:38pm
[2 replies] Last: Oh, dear. It compiles now. Thanks. (by beko)
template return type
Hi, i need help here , av gotta snippet here and i need to identify what causes the error. template<typename T> using ret_tuple=std::tuple<std::vector<std::s...
Jan 28, 2015 at 12:27pm
[6 replies] Last: ooh thanks n yea av got yet another function evaluate but i could p... (by closed account SECMoG1T)
C Progarm to compare two text files
Hii All, i am a begginer at c programming in the first semetser of study, and i am trying to doing my project what is: Diff — The program should compar...
Jan 28, 2015 at 12:25pm
[1 reply] : Determining where changes begin and end between two files is not a tri... (by AbstractionAnon)
Gui advice, what to use for more than just menus
I have two projects I want to do, the first as a learning test for doing the second. I have never made a gui, so for my first gui project, I have a very simp...
Jan 28, 2015 at 11:18am
[1 reply] : I want to make a launcher for windows, that basically replaces the no... (by MiiNiPaa)
Quiz game
this code is generates Assertion failure at line 33 #include<iostream> #include<fstream> #include<string.h> #include<stdlib.h> #include<time.h> usi...
Jan 28, 2015 at 9:00am
[1 reply] : This assertion might be raised due to a lack of the terminating '\0'. ... (by coder777)
by Nanyo
open with...
hello I am trying to open a .ps1 file(powershell file) with a C++ program. The problem I meet is that the .ps1 file is opening in Powershell ISE. I want to make...
Jan 28, 2015 at 8:19am
[5 replies] Last: I normally associate the .ps1 file with the Powershell command line, ... (by MiiNiPaa)
by sjabat
vector average and searching of agility
#include <iostream> #include <vector> #include <string> #include <sstream> #include <algorithm> using namespace std; int main() { int counter=0; string str; ...
Jan 28, 2015 at 8:07am
[1 reply] : average of what? find what? You can't just dump your code and expe... (by OxBADC0DE)
check repeated elements on different length vectors
I basically need to figure out what's the best way of checking for repeated elements on multiple vectors that have different lengths and then return those eleme...
Jan 28, 2015 at 7:59am
[1 reply] : Any suggestions? Check how the existing algorithms are implemente... (by OxBADC0DE)
by sofi
While loop
Hello, I am trying to get a while loop to work only while a number is divided by 2 and stop once the result is 1 but can not quite figure out how to do it. Wh...
Jan 28, 2015 at 7:53am
[5 replies] Last: Yes, one iteration of a loop can execute so other "nested" loop. Howe... (by keskiverto)
Knight's Tour + heuristics
From Wikipedia for the uninformed: "A knight's tour is a sequence of moves of a knight on a chessboard such that the knight visits every square only once." I...
Jan 28, 2015 at 7:37am
[2 replies] Last: You are correct, my description was not at all accurate! Maybe I need ... (by sarmar610)
Creating a class once and passing it independently to other objects
I have a class called LoaderAnimation, which basically displays a sequence of 112 images when particles on the screen are hovered. I was initially creating a...
Jan 28, 2015 at 6:01am
[3 replies] Last: I figured it out. I think the observer pattern approach worked perfect... (by sheva29)
%d in printf
Hello All, I want to know the difference between %d and %"PRIdPTR" in C.... And I want to know where exactly is PRIdPTR used? Is it similar to intptr_t? I tried...
Jan 28, 2015 at 4:41am
[3 replies] Last: From the Posix specification: APPLICATION USAGE The purpose of <intty... (by JLBorges)
by kiri
error because of cin?
Every time I type this up and use cin at the beginning to enter the company name all the numbers go crazy. Anyone have a clue why, I have spent hrs trying to fi...
Jan 28, 2015 at 4:13am
[8 replies] Last: geniusberry, thanks I am going 2 look into it and try to learn more ab... (by kiri)
C string turning to junk when leaving a function
Hey guys I am trying to create an open file function that checks the file type, I've done that but now when it leave the function it is turning to junk, Im usin...
Jan 28, 2015 at 4:12am
[9 replies] Last: You don't even need fileName in openFile, just use the file parameter:... (by dhayden)
January 2015 Pages: 1... 45678... 39
  Archived months: [dec2014] [feb2015]

This is an archived page. To post a new message, go to the current page.
Registered users can post in this forum.