Web Log di Adrian Florea

"You know you've achieved perfection in design, not when you have nothing more to add, but when you have nothing more to take away." Antoine de Saint-Exupery
posts - 440, comments - 2715, trackbacks - 3944

My Links

Archives

Post Categories

Image Galleries

.RO Blogs

.RO People

.RO Sites

Blogs

Furls

Links

vinCitori

Quiz Sharp 2

using System;
class M
{
  static void Main()
  {
    int i = 1;
    double d;
    try
    {
      d = 1.0/0;
      i = 2;
      d = 1/0.0;
      i = 3;
      d = 1/String.Empty.Length;
    }
    catch(DivideByZeroException e)
    {
      Console.WriteLine(i);
    }
    Console.ReadLine();
  }
}

Cosa scrive sulla console?

  • A. 1;
  • B. 2;
  • C. 3.

P.S.: l'iniziale della classe, M, è per M.rkino - sa lui perché :-)

Print | posted on martedì 18 maggio 2004 21:54 | Filed Under [ Quiz Sharp ]

Powered by:
Powered By Subtext Powered By ASP.NET