2. CodeFurther...
Examples of projects…
• Display the PREMIER LEAGUE football table!
• Get the WEATHER FORECAST for tomorrow…and send it in
an EMAIL to someone!
• Get a list of the most popular SONGS at the moment and
send a TWEET about it!
• Get SONG LYRICS for your favourite song, and send a TEXT
to a mobile phone!
4. CodeFurther...
Example Code - Directions
1. Head south on Stamshaw Rd/A3 toward Derby Rd (0.4 km / 1 min)
2. At the roundabout, take the 4th exit onto the M275 ramp to M27 (0.7…
3. Merge onto M275 (2.0 km / 1 min)
4. At junction 12, exit toward Southampton/Fareham (0.7 km / 1 min)
5. Merge onto M27 (17.5 km / 10 mins)
6. At junction 8, take the A3024 exit to Southampton/East Docks/Hamble…
7. At the roundabout, take the 1st exit onto A3024 (0.4 km / 1 min)
8. At the roundabout, take the 3rd exit onto Bursledon Rd/A3024 (0.9 km…
9. Turn left onto Botley Rd/B3033 (1.5 km / 2 mins
10. At the roundabout, take the 2nd exit onto Portsmouth Rd/A3025…
11. Turn left onto Terminus Terrace/A33 (78 m / 1 min)
12. Turn right onto Bernard St/A33 (0.1 km / 1 min)
13. Turn right onto Threefield Ln/A33 (0.2 km / 1 min)
14. Slight left onto Evans St/A33 (0.2 km / 1 min)
15. Take the 1st left onto Houndwell Pl (0.2 km / 1 min)
16. At the roundabout, take the 3rd exit onto Palmerston Rd (0.3 km /…
17. Turn left onto Pound Tree Rd (0.2 km / 1 min)
18. Pound Tree Rd turns right and becomes Above Bar St (0.5 km / 2 mins)
from codefurther.directions import GetDirections
directions = GetDirections(
'Portsmouth',
'Southampton',
'driving‘
)
for step in directions.steps:
print(step)
5. CodeFurther...
Example Code - Football
Premier League 2014/15 - Matchday 22
# Team Plyd GlsF GlsA GD Pts
-- ------------------------------ ---- ---- ---- ---- ----
1 Chelsea FC 22 51 19 32 52
2 Manchester City FC 22 45 22 23 47
3 FC Southampton 22 37 16 21 42
4 Manchester United FC 22 36 21 15 40
5 FC Arsenal London 22 39 25 14 39
6 Tottenham Hotspur FC 22 32 30 2 37
7 West Ham United FC 22 35 25 10 36
8 Liverpool FC 22 31 27 4 35
9 Swansea City 22 26 30 -4 30
10 Stoke City FC 22 23 27 -4 29
11 Newcastle United 22 26 35 -9 27
12 Everton FC 22 30 34 -4 23
13 Crystal Palace 22 25 33 -8 23
14 West Bromwich Albion 22 20 29 -9 22
15 Aston Villa FC 22 11 25 -14 22
16 Sunderland AFC 22 19 33 -14 20
17 FC Burnley 22 21 36 -15 20
18 Hull City FC 22 20 30 -10 19
19 Queens Park Rangers 22 23 39 -16 19
20 Leicester City 22 20 34 -14 17
from codefurther.football import premier_league
for league_entry in premier_league.league_table:
print(league_entry)
6. CodeFurther...
Example Code - Lyrics
When your legs don't work like they used to before
And I can't sweep you off of your feet
Will your mouth still remember the taste of my love
Will your eyes still smile from your cheeks
And darling I will be loving you till we're 70
And baby my heart could still fall as hard at 23
And I'm thinking 'bout how people fall in love in mysterious ways
Maybe just the touch of a hand
Oh me I fall in love with you every single day
And I just wanna tell you I am
So honey now
Take me into your loving arms
Kiss me under the light of a thousand stars
Place your head on my beating heart
I'm thinking out loud
That maybe we found love right where we are
When my hair's overgone and my memory fades
And the crowds don't remember my name
When my hands don't play the strings the same way
I know you will still love me the same
'Cause honey your soul can never grow old
It's ever green
Baby your smile forever in my mind and memory
And I'm thinking 'bout how people fall in love in mysterious ways
Maybe it's all part of a plan
I'll just keep on making the same mistakes
Hoping that you'll understand
But baby now
.
.
.
from codefurther.lyrics import Lyrics
lyrics = Lyrics()
result = lyrics.song_lyrics(
"Ed Sheeran",
"Thinking out loud“
)
for line in result:
print(line)
7. CodeFurther...
Example Code – Top40 Charts
1 Uptown Funk (feat. Bruno Mars) Mark Ronson 7 1
2 Lips Are Movin Meghan Trainor 7 50
3 Take Me To Church Hozier 26 3
4 Wish You Were Mine Philip George 4 2
5 Up (feat. Demi Lovato) Olly Murs 9 4
6 Thinking Out Loud Ed Sheeran 31 5
7 Heroes (We Could Be) (feat. Tove Lo) Alesso 5 7
8 The Nights Avicii 3 16
9 Blank Space Taylor Swift 13 6
10 Something I Need Ben Haenow 6 8
11 Elastic Heart Sia 7 13
12 Like I Can Sam Smith 14 10
13 Real Love Clean Bandit & Jess Glynne 10 12
14 All About That Bass Meghan Trainor 21 11
15 I Loved You (feat. Melissa Steel) Blonde 8 15
16 Outside (feat. Ellie Goulding) Calvin Harris 12 14
17 Cool Kids Echosmith 8 28
18 Promesses (feat. Kaleem Taylor) Tchami 3 9
19 Shake It Off Taylor Swift 23 26
20 Budapest George Ezra 39 17
21 I'm Not The Only One Sam Smith 28 21
22 Chandelier Sia 30 19
23 Dangerous (feat. Sam Martin) David Guetta 10 22
24 Blame It On Me George Ezra 29 25
25 Night Changes One Direction 11 18
26 Wrapped Up (feat. Travie McCoy) Olly Murs 10 20
27 Stay With Me Sam Smith 36 24
28 Bang Bang Jessie J, Ariana Grande & Nicki Minaj 18 23
29 Hold Back The River James Bay 9 31
30 These Days Take That 9 27
31 Don't Tell 'Em (feat. Y.G.) Jeremih 16 32
32 Don't Ed Sheeran 31 29
33 All Of Me John Legend 54 33
34 Steal My Girl One Direction 15 30
35 Sing Ed Sheeran 34 35
36 Changing (feat. Paloma Faith) Sigma 21 37
37 Blame (feat. John Newman) Calvin Harris 20 36
38 Prayer In C (Robin Schulz Remix) Lilly Wood 24 38
39 7/11 Beyoncé 9 34
40 Rather Be (feat. Jess Glynne) Clean Bandit 53 39
from codefurther.top40 import Top40
top40 = Top40()
for single in top40.singles:
print(single)
8. CodeFurther...
Example Code – Weather Forecast
Tomorrow's forecast for Portsmouth, UK is Drizzle in the
morning. The temperature will be between 3.14 and 7.86.
from codefurther.weather import Weather
forecast = Weather()
tomorrows_weather = forecast.tomorrow(
"Portsmouth, UK“
)
print(tomorrows_weather)
14. CodeFurther...
My questions to you…
• Does this look interesting?Concept
• What is the likely age range?
• Is this suitable in lesson or for an after school club?Age / Capability
• Social communication in the school context?
• Installation and data ‘issues’Cons/Problems/Concerns
• IMDB, NASA Mission Data, iTunes trending, Google Maps,
Search twitter, etc.Other data
• xSMS, Tweets, Email, Google+, Facebook, Guttenberg library,
Snapchat, Flickr, Instagram, Complete web sites, etc.
Other Social
Communication