State the number of bytes occupied by char and int data types.

1 Answer

Answer :

Ans. char occupies two bytes and int occupied 4 bytes.

Related questions

Description : If an integer occupies 4 bytes and a character occupies 1 byte of memory, each element of the following structure would occupy how many bytes ? struct name { int age; char name[30]; }; A) 30 B) 32 C) 34 D) 36

Last Answer : C) 34

Description : Classify the following as primitive or non-primitive data types: (i) char (ii) arrays (iii) int (iv) classes

Last Answer : Ans. (i) char – Primitive (ii) arrays – Non primitive (iii) int – Primitive (iv) Classes – Non primitive

Description : Arrange the following primitive data types in an ascending order of their size: (i) char (ii) byte (iii) double (iv) int

Last Answer : Ans. The sizes of the given data types are as follows char = 2 bytes byte = 1 byte double = 8 bytes int = 4 bytes Arranging them in ascending order gives byte < char < int < double

Description : Classify the following as primitive or non-primitive data types: (i) char (ii) arrays (iii) int (iv) classes

Last Answer : Ans. (i) char – Primitive (ii) arrays – Non primitive (iii) int – Primitive (iv) Classes – Non primitive

Description : What are the types of casting shown by the following examples: (i) char c = (char)120; (ii) int x = ‘t’;

Last Answer : Ans. (i) Explicit casting (ii) Implicit casting

Description : Give output for following code: class student { int roll no; char name [14]; } s[6]; void main() { cout<<sizeof(s); }

Last Answer : Considering roll_no(Single variable) the output is: 96 OR Considering roll, no (Two variables) the output is: 108 OR Considering roll no the output is: error – space between roll and no

Description : What will be the output of the following segment of the program? main( ) { char *s = “hello world”; int i = 7; printf(“%, *s”, i, s); } (A) Syntax error (B) hello w (C) hello (D) o world

Last Answer : Answer: Marks given to all

Description : Which of the following has compilation error in C ? (A) int n = 32; (B) char ch = 65; (C) float f= (float) 3.2; (D) none of the above

Last Answer : D

Description : A normal CD-ROM usually can store up to data? A) 680 KB B) 680 Bytes C) 680 MB D) 680 GB

Last Answer : Answer : C

Description : Can you tell what passes into and out from the computer via its ports? A) Data B) Bytes C) Graphics D) Pictures

Last Answer : Answer : A

Description : Which of the following are the best units of data on an external storage device? A) Bits B) Bytes C) Hertz D) Clock cycles

Last Answer : Answer : B

Description : The ascending order of a data hierarchy is: a) Bit - Bytes - Field - Record - File - Database b) Bit - Bytes - Record - Field - File - Database c) Bytes - Bit - Record - Field - File - Database d) None of The Above

Last Answer : a) Bit - Bytes - Field - Record - File - Database

Description : Which of the following are the best units of data on an external storage device? 1) Bits 2) Bytes 3) Hertz 4) Clock cycles

Last Answer : 2) Bytes

Description : Write the memory capacity (storage size) of short and float data type in bytes

Last Answer : Ans. short data type is of 2 bytes and float is of 4 bytes

Description : Which of the following are the best units of data on an external storage device? 1 Bits 2 Bytes 3 Hertz 4 Clock cycles

Last Answer : 2 Bytes

Description : What is the commonly used unit for measuring the speed of data transmission? A) Bytes per second B) BaudC) Bits per second D) Both B and C

Last Answer : B) Baud

Description : A Floppy Disc can store _____ data. (1) 1.44 bytes (2) 1.44 MB (3) 1.44 KB (4) 1.44 GB

Last Answer : 1.44 MB

Description : While creating a table named “Employee”, Mr. Rishi got confused as which data type he should chose for the column “EName” out of char and varchar. -Technology

Last Answer : Varchar would be the suitable data type for EName column as char data type is a fixed length data type while varchar is a variable length data type.Any employee‟s name will be of variable length so it‟s advisable to choose varchar over char data type.

Description : A cylinder contains 640 gm of liquid oxygen. The volume occupied (in litres) by the oxygen, when it is released and brought to standard conditions (0°C, 760 mm Hg) will be __________ litres. (A) 448 (B) 224 (C) 22.4 (D) Data insufficient; can't be computed

Last Answer : (A) 448

Description : Which of the following information about the UNIX file system is not correct? (A) Super block contains the number of i-nodes, the number of disk blocks, and the start of the list of free disk blocks. (B ... Each i-node is 256-bytes long. (D) All the files and directories are stored in data blocks. 

Last Answer : (C) Each i-node is 256-bytes long.

Description : One megabyte equals approximately 1) 1,000 bits 2) 1,000 bytes 3) 1 million bytes 4) 1 million bits 5) 2,000 bytes

Last Answer : Answer :3

Description : Which statement is valid? A) 1KB = 1024 bytes B) 1 MB=2048 bytes C) 1 MB = 1000 kilobytes D) 1 KB = 1000 bytes

Last Answer : Answer : A

Description : Which of the following is true? A) Fields are composed of bytes B) Records are composed of fields C) Fields are composed of characters D) All of above

Last Answer : Answer : D

Description : Which is valid statement A) 1 KB = 1024 Bytes B) 1 MB = 1024 Bytes C) 1 KB = 1000 Bytes D) 1 MB = 1000 Bytes

Last Answer : Answer : A

Description : The word length of a computer is measured in A) Bytes B) Millimeters C) Meters D) Bits

Last Answer : Answer : D

Description : The term gigabyte refers to A) 1024 bytes B) 1024 kilobytes C) 1024 megabytes D) 1024 gigabyte

Last Answer : Answer : C

Description : The memory unit is made up of _____ bytes. a) 256 b) 124 c) 4096 d) 3096

Last Answer : Answer: c Explanation: The memory unit is made up of 4,096 bytes. Memory unit is responsible for the storage of data. It is an important entity in the computer system

Description : Kilobyte equals to how many bytes? A. 1000 B. 1064 C. 1024 D. None of the above

Last Answer : C. 1024

Description : Find the incorrect one: a) 1 KB = 1024 BYTES b) 1 MB = 1024 KB c) 1 GB = 1024 MB d) 1 TB = 1024 GB e) 1 PB = 1024 TB f) None of These

Last Answer : f) None of These

Description : 1 Kilobyte (KB) is _______: a) 1000 bits b) 1 Kilo KB c) Both (a) and (b) d) 1024 Bytes e) None of The Above

Last Answer : d) 1024 Bytes

Description : Which among the following is correct: a) 1 KB = 8 Bytes b) 1 MB = 8 KB c) 1 KB = 1024 Bytes d) None of The Above

Last Answer : c) 1 KB = 1024 Bytes

Description : In computer language, one kilobyte equals 1) 1000 bytes 2) 1024 bytes 3) 100 bytes 4) 8 bytes

Last Answer : 2) 1024 bytes

Description : One Gigabyte is Approximately equal is 1) 1000,000 bytes 2) 1000,000,000 bytes 3) 1000,000,000,000 bytes 4) None of these

Last Answer : 2) 1000,000,000 bytes

Description : One kilobyte is equal to 1) 1000 bytes 2) 1024 bytes 3) 100 bytes 4) 1023 bytes

Last Answer : 2) 1024 bytes

Description : 1024 bytes equals: 1) 1 KB 2) 2 MB 3) 1 GB 4) 1TB

Last Answer : 1) 1 KB

Description : 1024 bytes equals: 1 1 KB 2 2 MB 3 1 GB 4 1TB

Last Answer : 1 1 KB

Description : Speed of processor chip is measured in (1) Mbps (2) MHz (2) Bits/second (4) Bytes/second

Last Answer : MHz

Description : 1024 bytes equals : (1) 1 TB (2) 1 GB (3) 1 MB (4) 1 KB

Last Answer : 1 KB

Description : Who manufactures non-activated carbon char?

Last Answer : my husband advises: try hickman-williams & co, oak brook, IL, or superior graphite company, chicago, IL, or asbury graphite company, asbury, NJ. these companies produce and market specialty carbon products; or they may know someone who does

Description : Who built Char Minar? -General Knowledge

Last Answer : The answer is 'Quli Qutb Shah'

Description : Who built Char Minar? -General Knowledge

Last Answer : answer:

Last Answer : On the Bangladesh-India border in Rajshahi district ( 3,000 feet long and 200 feet wide).

Last Answer : : Famous for fishing , dry production and coastal greenery.

Last Answer : Patni Char is located in the Sundarbans.

Last Answer : Located on Hatia Island in Noakhali.

Last Answer : Haor and Char Development Institute is located at Mithamin , Kishoreganj.

Last Answer : : A haor is a large body of water. Where water accumulates.

Last Answer : The largest char in Bangladesh is Dublar Char

Last Answer : Char Kukri Mukri to the south, Bay of Bengal to the north, Shahbazpur system and Char Manika to the east, Dhalchar to the west, Char Montaz.

Last Answer : Muhuri Char is located in Feni district.