Questions tagged as 'c++'

1
answer

Operator & e * in functions

What is the meaning of this & in the front of the array (my function only works with & amp ;, I'm overloading cout <
asked by 03.10.2016 / 07:14
1
answer

How do I use power in C ++? [closed]

I'm making a simple calculator, and wanted to add power. I've tried Pow() and did not, do you need to add some class?     
asked by 11.03.2018 / 22:47
2
answers

Calculate a sequence of triangular numbers less than 1000

I'm a beginner in programming and I'm having trouble with the following problem:    Make a program that calculates and prints all triangular numbers smaller than 1000.       A triangular number is a natural number that can be represented...
asked by 15.08.2018 / 16:00
3
answers

How to use an if within the other?

The problem is the following 2 soccer teams, wanted to create a decision where it would show "Brazil won" or "Argentina Won" or "There was a tie." But I can not make three decisions, here is my code below. #include<iostream> using nam...
asked by 27.06.2016 / 18:23
2
answers

How could I insert the structs into a list? [closed]

#include "stdafx.h" #include <iostream> using namespace std; struct FICHA_INSCRICAO { char nome[50]; char cpf[10]; char logradouro[100]; char bairro[20]; char cidade[20]; char estado[1]; char email[50]; cha...
asked by 07.10.2016 / 23:09
2
answers

Programming language directly with hardware [closed]

I will make applications that require a direct connection with the hardware, for example, a programmable mini-robot that receives information from one sensor and sends it to the programming to treat and return the correct action to another card...
asked by 03.08.2015 / 19:46
2
answers

Create files in the Home folder with C ++

In c ++, creating files is very simple, just include the fstream library and use ofstream arquivo; file.open ("variables.txt"); However this generates the file in the project folder and I would like to generate the file in some other fol...
asked by 19.04.2018 / 01:53
3
answers

warning: control end of non-void function - c ++

I'm doing a function to return the maximum and I'm having problems ... #include <iostream> #include <cstdio> using namespace std; int max_of_four(int a, int b, int c, int d){ if(a > b){ if (a > c){ if...
asked by 02.01.2018 / 02:46
3
answers

Allocator and placement new

I have a problem with placement new along with a "homemade allocator". The problem is that for data types (int) it works fine, now for double, very strange outputs start to appear. Classes: #include <cstdlib> template<class T>...
asked by 07.02.2014 / 18:28
3
answers

Using data type modifiers

Interestingly, I really wanted to know why data type modifiers are not so widely used. It is said that the modifiers are used to "efficienize" program performance, since you specify to the computer exactly the type of information that will be co...
asked by 13.09.2016 / 21:14