# How can I measure the execution time of my program locally?

**URL:** <https://discuss.codechef.com/t/how-can-i-measure-the-execution-time-of-my-program-locally/1865>\
**Category:** faq\
**Tags:** execution-time, faq\
**Created:** [April 10, 2013, 3:29pm UTC](https://discuss.codechef.com/t/how-can-i-measure-the-execution-time-of-my-program-locally/1865 "2013-04-10T15:29:55Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![admin](https://discuss.codechef.com/user_avatar/discuss.codechef.com/admin/32/212587_2.png) [@admin](https://discuss.codechef.com/u/admin)\
**Post date:** [April 10, 2013, 3:53pm UTC](https://discuss.codechef.com/t/how-can-i-measure-the-execution-time-of-my-program-locally/1865/3 "2013-04-10T15:53:18Z")

</div>

In unix, if your output file is called out.txt, you can get the execution time with the command time ./out.txt. Otherwise, you could just use functions from your programming language which measure the time at the start and end, and print out the difference.

---

_[View the full topic](https://discuss.codechef.com/t/how-can-i-measure-the-execution-time-of-my-program-locally/1865)._
