Top "Unary-operator" questions

How to printf a memory address in C

My code is: #include <stdio.h> #include <string.h> void main() { char string[10]; int A = -73; …

c pointers printf memory-address unary-operator
++someVariable vs. someVariable++ in JavaScript

In JavaScript you can use ++ operator before (pre-increment) or after the variable name (post-increment). What, if any, are the differences …

javascript increment unary-operator
What does the unary plus operator do?

What does the unary plus operator do? There are several definitions that I have found (here and here) but I …

c# c++ c unary-operator
encounter "unary operator expected" in bash script

in my bash script, I have a function to return 0 or 1(true or false) for the later main function's condition. …

bash if-statement unary-operator
What is the purpose of the unary plus (+) operator in C?

In C, it's legal to write something like: int foo = +4; However, as far as I can tell, the unary plus (+) …

c expression evaluation unary-operator
Difference of Unary operators ( += , =+ , ++x , x++ )

What is the difference between these unary operators in C# ? . Can you provide me with example? Please provide the name …

c# unary-operator
C: unary minus operator behavior with unsigned operands

I can't seem to find the relevant parts in the C standard fully defining the behavior of the unary minus …

c unary-operator
Multiple unary operators in an if statement

Is it possible to have multiple unary operators in if statements.. Here is the code snippet which is giving me …

bash if-statement syntax unary-operator
Scala - Prefix Unary Operators

I've recently given Scala a second chance, and started with the project I always implement (in functional or pseudo-functional languages): …

scala logic notation unary-operator
Java Expression Parser & Calculator Shunting Yard Algorithm

So the task is to create our own parser for a expression calculator. For Example: Input: 3+2*1-6/3 Output: 3 Input: 3++2 Output: …

java expression unary-operator shunting-yard