Updated Examples and Recipes (markdown)

Howard Hinnant
2017-07-08 11:43:09 -04:00
parent a3eecf003d
commit 0270da9c0c

@@ -104,7 +104,7 @@ main()
std::cout << date::format("%T\n", sy.get_local_time() - la.get_local_time());
}
```
Let's say you want to find out how many hours ahead Sydney is from LA (now). First get the current UTC time. Then create a `zoned_time` for both "America/Los_Angeles" and "Australia/Sydney" using that current UTC time. Then subtract their `local_time`s. `make_time` is a handy formatting tool for printing out that duration:
Let's say you want to find out how many hours ahead Sydney is from LA (now). First get the current UTC time. Then create a `zoned_time` for both "America/Los_Angeles" and "Australia/Sydney" using that current UTC time. Then subtract their `local_time`s. `format` is a handy formatting tool for printing out that duration:
17:00:00.000000