Questions tagged as 'operadores'

4
answers

How can I make a code with a string work with or?

Apparently I'm having problems with strings : public partial class Form1 : Form { private int _adicionar; private int _retirar; public Form1() { InitializeComponent(); } private void _Random_Click(object send...
asked by 19.05.2016 / 15:38
2
answers

What is the difference between assigning and comparing string variables with function or with assignment and comparison operator?

I came across the following questions: What is the difference between the expressions strcpy (s, t) e s = t ? What is the difference between the expressions if (strcmp (s, t) < 0) e if (s < t)  ? I tried to compile...
asked by 11.08.2015 / 00:44
3
answers

Problems with "or" in C ++

I need to make an algorithm that gets 3 different numbers, and if it receives repeated numbers, it informs an error message. My program is all working properly, but when I put the line to warn of the error I try to use Or and it does n...
asked by 06.03.2015 / 01:12
1
answer

Difficulty in Syntax

I would like you to explain this function to me, I do not understand this syntax: double sum_arithmetic(double x0, double r, int n) { return n == 0 ? 0 : x0 + sum_arithmetic(x0 + r, r, n-1); }     
asked by 29.09.2014 / 00:52
2
answers

Method equivalent to BigInteger.and () in C #

I need to convert the java code below to C #: public static boolean verificaPermissao(BigInteger perm1, BigInteger perm) { if (perm1 == null || perm == null || (perm1.equals(BigInteger.ZERO) || (perm.equals(BigInteger.ZERO)))) ret...
asked by 04.05.2017 / 19:15
2
answers

What is the purpose of the = operator in MySQL?

SELECT * FROM 'client' WHERE avatar <=> NULL This returned the only two items you have in the database, both for <=> and = . Another test I did was with <=> , which returns all items that the =...
asked by 09.06.2017 / 21:46
2
answers

What is the purpose of the operator = in the use of lists?

What is the purpose of the => operator in the use of List<T> lists, I'm starting to use generic lists and I came across this operator, it is only used in this method LISTA.ForEach(i => Console.WriteLine(i)); ? Below...
asked by 20.11.2015 / 01:23
4
answers

What is the difference between '==' and '===' operators in JavaScript? [duplicate]

I would like to know the difference between the two operators that would be: (1): == (2): === If possible, I would also like to understand the use of their opposite operators in this case: (3): != (4)...
asked by 30.01.2014 / 17:01
3
answers

How to divide integers and get value with decimal part?

I'm trying to divide the following values into C #: Double media = 0.0; int soma = 7; int cont = 2; media = soma / cont; You are returning 3 .     
asked by 10.07.2017 / 15:51
3
answers

Use OR operator in a CASE in PHP

How to use the or operator in a control structure switch ? Example switch ($options) { case 1 || case 2: echo "Valor de opção 1 e 2"; break; case 3: echo "Valor de opção 3"; break; }  ...
asked by 10.04.2015 / 21:58