<<= Back Next =>>
You Are On Multi Choice Question Bank SET 198

9901. Which of the following statements are correct? All operators in C#.NET can be overloaded. We can use the new modifier to modify a nested type if the nested type is hiding another type. In case of operator overloading all parameters must be of the different type than the class or struct that declares the operator. Method overloading is used to create several methods with the same name that performs similar tasks on similar data types. Operator overloading permits the use of symbols to represent computations for a type.





9902. Which of the following statement is correct about the C#.NET code snippet given below? public class Sample { public int x; public virtual void fun() { } } public class DerivedSample : Sample { new public void fun() { } }





9903. The study of diseases is..............





9904. Which of the following operators cannot be overloaded? true false new ~ sizeof





9905. Which of the following modifier is used when a virtual method is redefined by a derived class?






9906. In order for an instance of a derived class to completely take over a class member from a base class, the base class has to declare that member as






9907. Which of the following can be declared as a virtual in a class? Methods Properties Events Fields Static fields





9908. Choose the antonyms IGNOBLE





9909. Which of the following are necessary for Run-time Polymorphism? The overridden base method must be virtual, abstract or override. Both the override method and the virtual method must have the same access level modifier. An override declaration can change the accessibility of the virtual method. An abstract inherited property cannot be overridden in a derived class. An abstract method is implicitly a virtual method.





9910. Which of the following unary operators can be overloaded? true false + new is





9911. A derived class can stop virtual inheritance by declaring an override as






9912. Which of the following keyword is used to change the data and behavior of a base class by replacing a member of a base class with a new derived member?






9913. The policeman warned the photogrpaher ............too near.





9914. Which of the following keyword is used to overload user-defined types by defining static member functions?






9915. Select the correct statement from the following:





9916. The correct sentence is





9917. Pandemonium means





9918. The train passes........ a long tunnel





9919. What is common between parrot, platypus and kangaroo?





9920. If Sample class has a Length property with get and set accessors then which of the following statements will work correctly? Sample.Length = 20; Sample m = new Sample(); m.Length = 10; Console.WriteLine(Sample.Length); Sample m = new Sample(); int len; len = m.Length; Sample m = new Sample(); m.Length = m.Length + 20;





9921. Which of the following is the correct way to implement a write only property Length in a Sample class?





9922. A property can be declared inside a namespace or a procedure.



9923. If a Student class has an indexed property which is used to store or retrieve values to/from an array of 5 integers, then which of the following are the correct ways to use this indexed property? Student[3] = 34; Student s = new Student(); s[3] = 34; Student s = new Student(); Console.WriteLine(s[3]); Console.WriteLine(Student[3]); Student.this s = new Student.this(); s[3] = 34;





9924. If Sample class has a Length property with set accessor then which of the following statements will work correctly?






9925. If Sample class has a Length property with get accessor then which of the following statements will work correctly?






9926. An Account class has a property called accountNo and acc is a reference to a bank object and we want the C#.NET code snippet given below to work. Which of the following options will ensure this functionality? acc.accountNo = 10; Console.WriteLine(acc.accountNo);






9927. Suppose a Student class has an indexed property. This property is used to set or retrieve values to/from an array of 5 integers called scores[]. We want the property to report "Invalid Index" message if the user attempts to exceed the bounds of the array. Which of the following is the correct way to implement this property?





9928. Which of the following statements is correct about properties used in C#.NET?





9929. Which of the following is the correct way to implement a read only property Length in a Sample class?





9930. Which of the folowing does an indexer allow to index in the same way as an array? A class A property A struct A function An interface





9931. An Employee class has a property called age and emp is reference to a Employee object and we want the statement Console.WriteLine(emp.age) to fail. Which of the following options will ensure this functionality?






9932. A property can be declared inside a class, struct, Interface.



9933. This young man can get along not only with girls, but also with _____ parents.





9934. A Student class has a property called rollNo and stu is a reference to a Student object and we want the statement stu.RollNo = 28 to fail. Which of the following options will ensure this functionality?






9935. If a class Student has an indexer, then which of the following is the correct way to declare this indexer to make the C#.NET code snippet given below work successfully? Student s = new Student(); s[1, 2] = 35;





9936. Which of the following statements are correct? The signature of an indexer consists of the number and types of its formal parameters. Indexers are similar to properties except that their accessors take parameters. Accessors of interface indexers use modifiers. The type of an indexer and the type of its parameters must be at least as accessible as the indexer itself. An interface accessor contains a body.





9937. My father has not come home ______.





9938. The synonym of ‘dig’ is:





9939. The suggestion was accepted by ..................... unanimous vote.





9940. What is true about Nereis, Scorpion, Cockroach and Silver fish?





9941. Inspite of repeated failure he did not give ...... his attempt.





9942. If s1 and s2 are references to two strings, then which of the following is the correct way to compare the two references?






9943. What will be the output of the C#.NET code snippet given below? namespace IndiabixConsoleApplication { class SampleProgram { static void Main(string[ ] args) { string str= "Hello World!"; Console.WriteLine( String.Compare(str, "Hello World?" ).GetType() ); } } }






9944. Which of the following snippets are the correct way to convert a Single into a String? Single f = 9.8f; String s; s = (String) (f); Single f = 9.8f; String s; s = Convert.ToString(f); Single f = 9.8f; String s; s = f.ToString(); Single f = 9.8f; String s; s = Clnt(f); Single f = 9.8f; String s; s = CString(f);





9945. Which of the following will be the correct output for the C#.NET code snippet given below? String s1="Kicit"; Console.Write(s1.IndexOf('c') + " "); Console.Write(s1.Length);






9946. Which of the following is correct way to convert a String to an int? String s = "123"; int i; i = (int)s; String s = "123"; int i; i = int.Parse(s); String s = "123"; int i; i = Int32.Parse(s); String s = "123"; int i; i = Convert.ToInt32(s); String s = "123"; int i; i = CInt(s);





9947. Which of the following statements about a String is correct?






9948. Which of the following statement is correct about a String in C#.NET?






9949. Which of the following will be the correct output for the C#.NET code snippet given below? String s1 = "Five Star"; String s2 = "FIVE STAR"; int c; c = s1.CompareTo(s2); Console.WriteLine(c);






9950. If s1 and s2 are references to two strings then which of the following are the correct ways to find whether the contents of the two strings are equal? if(s1 = s2) if(s1 == s2) int c; c = s1.CompareTo(s2); if( strcmp(s1, s2) ) if (s1 is s2)





<<= Back Next =>>
Terms And Service:We do not guarantee the accuracy of available data ..We Provide Information On Public Data.. Please consult an expert before using this data for commercial or personal use | Powered By:Omega Web Solutions
© 2002-2017 Omega Education PVT LTD...Privacy | Terms And Conditions