Created
August 8, 2016 07:08
-
-
Save edib/96355b0bcf8173bfc56df25489633801 to your computer and use it in GitHub Desktop.
awk sum
This file contains 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
a file with hours:minutes:seconds | |
00:38:14 | |
16:31:37 | |
03:49:50 | |
04:14:06 | |
07:21:27 | |
03:10:47 | |
02:30:22 | |
01:45:49 | |
28:02:08 | |
04:56:31 | |
03:20:18 | |
12:58:11 | |
07:28:36 | |
23:55:50 | |
28:37:03 | |
30:35:27 | |
28:27:10 | |
08:00:46 | |
04:39:05 | |
04:07:34 | |
01:44:26 | |
02:45:44 | |
02:44:30 | |
05:34:53 | |
03:16:12 | |
01:30:40 | |
30:54:52 | |
43:37:29 | |
06:30:33 | |
08:53:49 | |
00:59:56 | |
22:57:10 | |
02:17:57 | |
07:11:33 | |
08:10:28 | |
18:02:05 | |
03:07:43 | |
cat file | awk '{ print $2}' | awk -F: '{ saat+=$1; dakika+=$2; saniye+=$3 } END { toplam=saat*60+dakika+saniye/60; print toplam/60 }' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment