All questions
- Which are relational operator? A relational operator checks the relationship between two operands. If the relation is true, it returns 1; if the relation is false, it retu... 1
- Give the general syntax of conditional operator? The conditional (ternary) operator is the only JavaScript operator that takes three operands: a condition followed by a question mark ( ? ),... 2
- What are major disadvantages of machine code? It is machine dependent i.e. it differs from computer to computer. It is difficult to program and write. It is prone to errors ,It is diffic... 1
- What is purpose of language processor? A language processor is a software program designed or used to perform tasks such as processing program code to machine code. 1
- What is language processor? Language processor may refer to: Natural language processor, a computer programmed to process human (natural) languages. Programming languag... 1
- Whether the program in c can be executed by computer directly? Answer: No. A C program (source code) cannot be executed by the computer directly; it must first be compiled into machine code. The computer... 1
- Describe the appearance of machine code? Answer: machine code looks like long strings of binary digits, 0s and 1s, for example 10110000 01100001. Machine code (machine language) is... 1
- How does a programmer finds coding errors? Test the program on simple cases for which the result of the program is known. Break down the program into a sequence of basic steps and ind... 1
- How long is a byte ? Answer: a byte is 8 bits long. A bit (binary digit) is the smallest unit of data, a single 0 or 1. A group of 8 bits makes one byte, for exa... 1
- How long is word? 4 bytes . 1
- What is global variable? The variables that are declared outside the given function are known as global variables. 2
- What is logical variable? Logical Variables are simply placeholders for values which are not yet known, like in mathematics 1
- What is main difference between variable and constant? A constant does not change its value over time. A variable, on the other hand, changes its value dependent on the equation. 1
- How many bytes are required to store double type value? . 8 bytes 2
- How many bytes are required to store char type value? Answer: 1 byte (8 bits). A char stores a single character. The C standard defines sizeof(char) as exactly 1 on every compiler. Internally th... 1
- How many bytes are required to store float type value? Answer: 4 bytes (32 bits). A float stores single-precision real numbers. On practically every C compiler (Turbo C, GCC, Visual C++) it takes... 1
- How many bytes are required to store integer type value? Answer: it depends on the compiler: 2 bytes in 16-bit compilers such as Turbo C, and 4 bytes in modern 32-bit/64-bit compilers such as GCC a... 1
- What is constant? in c Answer: a constant in C is a fixed value that cannot be changed while the program runs. Types of constants (literals): Integer constants: 10... 1
- What is variable? in c A variable is a name of the memory location. It is used to store data. Its value can be changed, and it can be reused many times. 1
- Python Program to Find the Largest Among Three Numbers num1 = float(input("Enter first number: ")) num2 = float(input("Enter second number: ")) num3 = float(input("Enter third number: ")) if (num... 1
- Python Program to Check Leap Year year = int(input("Enter a year: ")) # divided by 100 means century year (ending with 00) # century year divided by 400 is leap year if (year... 1
- Python Program to Check if a Number is Odd or Even num = int(input("Enter a number: ")) if (num % 2) == 0: print("{0} is Even".format(num)) else: print("{0} is Odd".format(num)) 1
- Python Program to Check if a Number is Positive, Negative or 0 num = float(input("Enter a number: ")) if num > 0: print("Positive number") elif num == 0: print("Zero") else: print("Negative number") 1
- Python Program to Convert Celsius To Fahrenheit celsius = 37.5 # calculate fahrenheit fahrenheit = (celsius * 1.8) + 32 print('%0.1f degree Celsius is equal to %0.1f degree Fahrenheit' %(c... 1