logo

Crowdly

Browser

Add to Chrome

Practical C#/.Net

Looking for Practical C#/.Net test answers and solutions? Browse our comprehensive collection of verified answers for Practical C#/.Net at softserve.academy.

Get instant access to accurate answers and detailed explanations for your course questions. Our community-driven platform helps students succeed!

Please, select the output of the code below:

public class PowersOf2     {         static void Main()         {             foreach (int i in Power(2, 5))             {                 Console.Write("{0} ", i);             }         }          public static IEnumerable<int> Power(int number, int exponent)         {             int result = 1;              for (int i = 0; i < exponent; i++)             {                 result = result * number;                 yield return result;             }         }     }

❌
✅
❌
❌
❌
❌
View this question

Please, choose the type that can be used as a return type in the declaration of an iterator with yield:

0%
0%
0%
0%
0%
View this question

Please, choose the members of the IEnumerator<T> interface:

❌
❌
✅
❌
✅
✅
❌
❌
View this question

Please, choose what is true about IEnumerable<T> interface:

✅
✅
✅
✅
View this question

Please, choose what will be the result of the execution of the code below:

interface A     {         void Hello();     }      interface B     {         void Hello();     }      class Test : A, B     {         public void Hello()         {             Console.WriteLine("Hello to all");         }     }     static void Main()     {         Test myTest = new Test();         myTest.Hello();     }

❌
❌
✅
❌
View this question
View this question

For the code snippet shown below, which of the following statements are valid?

❌
✅
❌
❌
❌
View this question

Please, choose what will be the result of the execution of the code below:

interface A     {         void Hello();     }      interface B     {         void Hello();     }      class Test : A, B     {         void A.Hello()         {             Console.WriteLine("Hello from A");         }         void B.Hello()         {             Console.WriteLine("Hello from B");         }     }     static void Main()     {         Test myTest = new Test();         ((A)myTest).Hello();     }

0%
0%
0%
0%
0%
View this question

What are the valid constraints on type parameters for

C# generic classes?

0%
0%
0%
0%
0%
0%
0%
0%
View this question

Please, choose what is true about interfaces:

0%
0%
0%
0%
0%
View this question

Want instant access to all verified answers on softserve.academy?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!

Browser

Add to Chrome