Beginners - October 2021 (Page 2)

problem of a simulator
solved.
Oct 26, 2021 at 4:54pm
[1 reply] : > printf("A = "); int a = (int)(fgets(buff, 64, stdin)); > printf("\n... (by salem c)
Pointer program that creates a memory map table
For a HW assignment I have to use an incomplete program with pointers to create a memory map table. How do I use a loop to create a table for this program? Prom...
Oct 26, 2021 at 4:54pm
[2 replies] Last: @seeplus cout << setw(15) << "Variable" << setw(15) << "CONTENTS" <<... (by gigacapybara)
the sequence of including headfiles
the sequence of including headfiles may affect the success of compilation. and now i am wondering if it is important to include headfiles in a particular seque...
Oct 26, 2021 at 1:17pm
[2 replies] Last: No, the ordering of standard library headers should not matter (assumi... (by Ganado)
help with _getch()
Hello! I am doing a work on project, during travelling I use my phone IDE (Cxxdroid) and when I am at home I use my laptop. For detection of keyboard input I ...
Oct 26, 2021 at 7:49am
[1 reply] : Both _kbhit() and _getch() are windows functions. How do get it to wor... (by coder777)
the confusion on c library
that is the description of c library in the website Reference: The elements of the C language library are also included as a subset of the C++ Standard library...
Oct 25, 2021 at 5:19pm
[3 replies] Last: Right, round also exists in the C standard library, so perhaps it wasn... (by Ganado)
Orphaned process doesn't receive SIGHUP
Hello! I have this simple fork code: int main(int argc, char const *argv ) { pid_t p = fork(); if (p == -1) { printf("error in fork leade...
Oct 25, 2021 at 11:56am
[1 reply] : https://linux.die.net/man/2/getppid Change this line. printf("test,... (by salem c)
by ALNLAA
A little help with switch statements
So i have a task : enter N , and a "social score". After which you write N amount of marks, for an F you get "-5" score , for a D "-3", for a C "-1" , and for ...
Oct 25, 2021 at 11:46am
[6 replies] Last: Friendly tip: When you say "it doesn't work", tell us specifically wha... (by Ganado)
by acprog
Show the array (nxm) and navigate it with cursor
Is there any way for showing a bidimensional array and navigate it using cursor - in console? I mean, show array is easy. But return with cursor How can I do...
Oct 25, 2021 at 11:19am
[3 replies] Last: It isn't especially hard, but it isn't simple. However, this is my re... (by Duthomhas)
by Jhokuu
[issue] code not reading for loop properly
An assignment from school that I'm having a little bit of issues with. The output after the first rotation of information input doesn't allow for the input of t...
Oct 25, 2021 at 8:47am
[2 replies] Last: #include <string> #include <iostream> constexpr size_t array_size {... (by seeplus)
urgent help with input problem
need help urgent. if the user enters y, or Y output = you are enrolled if the user enters n, or N output = you are not if the user enters anything el...
Oct 24, 2021 at 9:17pm
[1 reply] : The user can theoretically type in bad input, such as "abc", so you ne... (by Ganado)
How can i print argv
Hello How can i print all value for argv? Is this code are ok? Doest i need a terminal to see the result, or i can see it in c++ compiler? #include <stdio.h...
Oct 24, 2021 at 1:16pm
[2 replies] Last: https://en.cppreference.com/w/cpp/utility/program/EXIT_status (by ne555)
by derpus
Cannot output ansi colour codes with fstream
I'm having trouble with the outputting of strings containing ansi codes. #include <windows.h> #include <iostream> #include <fstream> #include <string>...
Oct 24, 2021 at 9:40am
[13 replies] Last: > if anybody could explain to me why using the '\e' in the text file d... (by salem c)
by sito20
Sales_item.h: no such file or directory
Hello all, I recently began teaching myself c++ with a book, c++ primer, and I just started with classes. But when I try compiling my file I get this error m...
Oct 23, 2021 at 5:26pm
[2 replies] Last: I found a link to a file with the header name on a subsequent page, th... (by sito20)
by jeyc
c++ login system
I'm new to c++ and I'm trying to create a login system for my school project this is my code: #include <iostream> #include<ctime> #include<string> #inc...
Oct 23, 2021 at 12:47pm
[1 reply] : welcome! please put code tags around this, edit your post and highlite... (by jonnin)
Can't handle signals after changing process group
Hello guys! I have this little code: struct sigaction sa; void signal_handler(int signum); int main(int argc, char const *argv ) { struct sigaction sa...
Oct 23, 2021 at 11:23am
[1 reply] : https://man7.org/linux/man-pages/man2/setpgid.2.html Scroll down to th... (by salem c)
Error trying to use a for loop with input validation using tolower() and .length()
*Disclaimer* This is a homework assignment, I asked my teacher about the issue and he gave me great advice, which I took. But I am stuck with the formatting of ...
Oct 23, 2021 at 6:16am
[10 replies] Last: Just keep posting in this thread, starting a new thread is ultimately ... (by TheIdeasMan)
by Jhokuu
Running into a snag with an error
so my goal here for this assignment is to re-arrange my array from largest to smallest I'm aware my code isn't quite there yet however I'm getting stuck on this...
Oct 23, 2021 at 3:10am
[2 replies] Last: foo.cpp|50 col 16| warning: unused parameter 'arr' [-Wunused-paramete... (by ne555)
Normal distribution random values sum to 1
Hello everyone, I need a small help. I need to generate random values between 0 and 1. They must be successively ordered. Let me give you an example. Starting ...
Oct 22, 2021 at 3:30pm
[15 replies] Last: @ lastchance,no, it is not you, it is me who could not explain the th... (by learner999)
by mar99
Searching string for a partial string, using structures: displays both 'found' and 'not found' statements?
This is for a program that uses structures to store data. customer is the structure that holds data for customer at index k, and it is looking through the stru...
Oct 22, 2021 at 12:21pm
[15 replies] Last: Perhaps (not tried): void findCustomer(const string& name) { size_... (by seeplus)
by BigTim
Making a bank account display certain amounts
This is my first year taking coding so I'm a bit confused cause I'm currently trying to work on this homework assignment that's a little late lol. I can make my...
Oct 22, 2021 at 1:49am
[1 reply] : sorry, what do you want it to do? Explain exactly what you want ... t... (by jonnin)
October 2021 Pages: 1234... 7
  Archived months: [sep2021] [nov2021]

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