Last active
September 6, 2023 08:37
-
-
Save admir-live/2b3fa2425d6396078f8dfb101f628b52 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System; | |
| using System.Threading.Tasks; | |
| public class Program | |
| { | |
| public static void Main() | |
| { | |
| Console.WriteLine("Starting main method."); | |
| LogApiCall("API endpoint called."); | |
| Console.WriteLine("Main method completed."); | |
| Console.ReadLine(); | |
| } | |
| public static async Task LogApiCall(string message) | |
| { | |
| await Task.Delay(2000); // Delay for 2 seconds to simulate the async operation | |
| Console.WriteLine($"Logged: {message}"); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment