plass: It works, but no SQL sanitization yet
[gpstools.git] / tilgps
blobbe641f79b21d238c5896532e5501103d7c8a42b2
1 #!/usr/bin/perl
3 # tilgps
4 # Converts gg°mm'ss.sss" to gg°mm.mmmmm'
6 use strict;
7 use warnings;
9 if ($#ARGV < 2) {
10 die(<<END);
12 Syntax: $0 degrees minutes secons
14 Converts gg°mm'ss.sss" to gg°mm.mmmmm'
15 Decimal values can be used.
17 END
20 my ($Deg, $Min, $Sec) = @ARGV;
21 my $new_min = $Min+($Sec/60);
23 print("$Deg°$new_min'\n");
25 __END__