Ändrat så att valutakursen hämtas via nätet
This commit is contained in:
parent
ee25830ebf
commit
608e4750a3
@ -4,8 +4,10 @@
|
|||||||
# LX13
|
# LX13
|
||||||
# Övning 2, labb 4
|
# Övning 2, labb 4
|
||||||
|
|
||||||
# Define some variables
|
# Get current exchange rate
|
||||||
Rate="6.3"
|
Rate=`curl -s http://www.valutakurser.nu/usd.html | \
|
||||||
|
grep "<td>Forex</td>" | awk '{print $10}' | \
|
||||||
|
egrep [0-9] | cut -b15-18`
|
||||||
|
|
||||||
# Run it
|
# Run it
|
||||||
printf "Do you want to convert from SEK or USD? "
|
printf "Do you want to convert from SEK or USD? "
|
||||||
|
Loading…
x
Reference in New Issue
Block a user