repl.it
@kironroy/

exceptionhandling

C#

No description

fork
loading
Files
  • main.cs
  • Calculator.cs
  • main.exe
  • notes.txt
  • Notes.txt
  • Video.cs
  • YouTubeApi.cs
  • YouTubeException.cs
main.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
using System;
using System.IO;

namespace ExceptionHandling
{
    class Program
    {
        static void Main(string[] args)
        {
            try
            {
                var api = new YouTubeApi();
                var videos = api.GetVideos("mosh");
               
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.Message);
            }
        }
    }
}