Knowee
Questions
Features
Study Tools

Which one of the following operators is a unary operator in c language? ans. sizeof() & && <<

Question

Which one of the following operators is a unary operator in c language?

ans. sizeof()

&

&&

<<

🧐 Not the exact question you are looking for?Go ask a question

Solution

The unary operators in C language from the given options are sizeof() and &.

  1. sizeof(): This operator is used to get the size of the variable, constant or data type. It returns the size in bytes.

  2. &: This is the address of operator. It is used to get the address of the variable.

The other two operators (&& and <<) are not unary operators.

  • &&: This is a logical AND operator. It takes two operands.
  • <<: This is a left shift operator. It also takes two operands.

This problem has been solved

Similar Questions

Which one of the following operators is a unary operator in c language? ans. & sizeof() << &&

Which one of the following operators is a unary operator in c language?

What is the purpose of the sizeof operator in C?A. It returns the size of a variable in bytesB. It returns the value of a variableC. It declares the size of an arrayD. It calculates the sum of two numbers

Understanding Unary operators#include <stdio.h>void main() { int a = 10, b; b = a++ + ++a; printf("%d %d\n", a, b);}What is the a = b =

Suppose that in a C program snippet, followings statements are used.i) sizeof(int);ii) sizeof(int*);iii) sizeof(int**);

1/3

Upgrade your grade with Knowee

Get personalized homework help. Review tough concepts in more detail, or go deeper into your topic by exploring other relevant questions.