Skip to content

A C# console timer built from scratch to practice time calculations and strengthen C# programming skills

Notifications You must be signed in to change notification settings

kevin-alxdr/timer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Timer

This is my attempt at making a Timer in C#. I started this project as a way to familiarise myself and practice with C# syntax. Although I am aware of a pre-existing Timer class that can be used to recreate what I have done, I wanted to challenge myself by attempting to build a timer myself from scratch, building on top of seconds to create minutes, and building on top of seconds and minutes to create hours.

 

New commands learned during the project

  • Console.SetWindowSize() - Sets the height and width of the console window to the specified values
  • Thread.Sleep() - Suspends the current thread for the specified amount of time

 

Improvements to be made

  • During the intial start up of the program, it asks the user to set a time, this input is not centered.
  • Code could be refactored to improve efficiency and overall readability, specifically the Hour.cs file.
  • Comments should be added to all custom methods to explain code and improve readability.

About

A C# console timer built from scratch to practice time calculations and strengthen C# programming skills

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages