Union in c 10

Quiz
•
Computers
•
University
•
Easy
Abhishek Pandey
Used 4+ times
FREE Resource
7 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following are collection of different data types
string
char
float
union
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
size of union is size of the longest data member in the union
True
false
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The size of the following union, where an int occupies 4 bytes of memory is
union demo
{
float x;
int y;
char z[10];
};
10
8
7
4
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Size of a structure is determined by size of the.
First member in the structure
Last member in the structure
Sum of the sizes of all members
sizes of largest members
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Union differs from structure in the following way
Only one member can be used at a time
Union cannot have more members
Union initialized all members as structure
all members are used at a time
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Int main()
{ union var { int a, b; };
union var v;
v.a=10;
v.b=20;
printf("%d\n", v.a);
return 0; }
10
30
20
all
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
int main(){
struct number
{
int no;
char name[20];
};
struct number s;
s.no = 50;
printf("%d", s.no);
}
5
3
50
Compile time error
Similar Resources on Wayground
10 questions
Programming for Problem Solving

Quiz
•
University
12 questions
javaquizvivek

Quiz
•
University
12 questions
Array

Quiz
•
University
10 questions
Summer Code Camp - Lesson 1

Quiz
•
University
10 questions
На сколько ты знаешь C#

Quiz
•
University
10 questions
Struktur Data

Quiz
•
University
10 questions
Basic C Knowledge Exercise

Quiz
•
University
10 questions
PreTest Larik/ Array

Quiz
•
11th Grade - University
Popular Resources on Wayground
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
9 questions
Tips & Tricks

Lesson
•
6th - 8th Grade
Discover more resources for Computers
21 questions
Spanish-Speaking Countries

Quiz
•
6th Grade - University
20 questions
Levels of Measurements

Quiz
•
11th Grade - University
7 questions
Common and Proper Nouns

Interactive video
•
4th Grade - University
12 questions
Los numeros en español.

Lesson
•
6th Grade - University
7 questions
PC: Unit 1 Quiz Review

Quiz
•
11th Grade - University
7 questions
Supporting the Main Idea –Informational

Interactive video
•
4th Grade - University
12 questions
Hurricane or Tornado

Quiz
•
3rd Grade - University
7 questions
Enzymes (Updated)

Interactive video
•
11th Grade - University