Novel Synth Company Interview Questions What is Interface Interface is similar to a class which may contain methodrsquos signature only but not bodies and it is a formal set of method and constant declarations that must be defined by the class that implements it. Interfaces are useful for a Declaring methods that one or more classes are expected to implement b Capturing similarities between unrelated classes without forcing a class relationship. Determining an objectrsquos programming interface without revealing the actual body of the class. What is Abstract class Abstraction the process of removing or hiding unnecessary information is called abstraction. The process of providing necessary method prototype by removing/ hiding unnecessary method logic/ body is called abstraction. Here unnecessary details mean method body and logic. It only provides us method prototypes and hides method implementation details. Hiding non essential details can be developed using concrete methods. Removing non essential details can be developed using abstract methods. What are the final, finalize, finally final final keyword can be used for class, method and variables. A final class cannot be subclassed and it prevents other programmers from subclassing a secure class to invoke insecure methods. A final method canrsquo t be overridden A final variable canrsquot change from its initialized value. finalize finalize method is used just before an object is destroyed and can be called just prior to garbage collection. finally finally, a key word used in exception handling, creates a block of code that will be executed after a try/catch block has completed and before the code following the try/catch block. The finally block will execute whether or not an exception is thrown. For example, if a method opens a file upon exit, then you will not want the code that closes the file to be bypassed by the exception-handling mechanism. This finally keyword is designed to address this contingency. In C programming in void main what is void Void main this is the main method in C programming here void is a return type itrsquos not return any value. Without void can we write main method in C language Is there any return types available for main in C programming Yes, we can write main method without Void Key word. And we give data type as return type to main method in C programming. What are the Structures in C Programming A structure is a collection of one or more variables, possibly of different data types, grouped together under a single name for convenient handling. typedef struct char name64 char course128 int age int year student Is there Arrays are available in Structures in C programming arrays of structures mean collection of structures, in other word array storing different type of structure member variables. Arrays of Structures are one of the interesting topics for C programmer because it has power of two powerful data types Structure and Array. elow is a product structure containing same member variables as in above example image has. struct product char name30 int stock float price, discount Reverse a number program includeltstdio.hgt int main int num,r,reverse0 printfquotEnter any number quot scanfquotdquot,num whilenum rnum10 reversereverse10r numnum/10 printfquotReversed of number dquot,reverse return 0 Sample output Enter any number 122 Reversed of number 221 C program to reverse a number using for loop includeltstdio.hgt int main int num,r,reverse0 printfquotEnter any number quot scanfquotdquot,num fornum0numnum/10 rnum10 reversereverse10r printfquotReversed of number dquot,reverse return 0 Sample output Enter any number 234 Reversed of number 432 C program to reverse a number using recursion includeltstdio.hgt int main int num,reverse printfquotEnter any number quot scanfquotdquot,num reverserevnum printfquotReverse of number dquot,reverse return 0 int revint num static sum,r ifnum rnum10 sumsum10r revnum/10 else return 0 return sum Sample output Enter any number 789 Reverse of number 987