It’s been a mixed start to the new year. Watching what I eat for the rest of January, damn you Christmas. Back at work after three weeks off, achieved nothing and left by eleven. My ego got the better of me and I went for a run despite having a cold, so am now suffering. Need to shift it with the first cross country league race on Wednesday. I can’t help wondering why generic medicines are so much cheaper than brand names.
Finally got around to ordering a replacement Acer V3-112P screen. Replacement was straight forward. Like most avionics technicians, I breathed a sigh of relief when the LED panel lit up proving the fault. The old girl is now sitting running a million updates courtesy of Microsoft.
While many Linux advocates eschew Microsoft, I prefer Office (Home Use Program). Like current, I take the path of least resistance and I use Word and Excel so often I know them inside out. Linux is an outstanding development platform, I’m using it for TM470.
TM470 project preparation continues, reviewing both TM353 and TM354. FutureLearn is a fantastic resource with a course on Secure Android Development. Delivered by the University of Southampton, it started last week. I haven’t decided the tool chain yet, particularly versioning. I have used SVN and Bazaar, which I prefer as it integrates well with Launch Pad. I won’t be using LP though so should investigate Mercurial and Git.
Read Original Sin too – best Marvel I’ve read in ages. Like Murder She Wrote in space. A real page turner, I read it in one sitting.
Something that didn’t grip me was the Assassin’s Creed movie. It starts off quite well, with a similar story to the games. It suffers the same problem as earlier games though – the present interrupts more interesting stories in the past. What I don’t get though is why option a game as a property then try not to appeal to that market?
What I haven’t made time for though is the Nintendo Classic Mini. I played a little Ghosts ‘n Goblins – damn I forgot how hard games were then. I always thought as a kid that I’d somehow be better at them as an adult but I guess I didn’t factor in reactions.
An Android fitness tracker application. Feedback from the preparation forum was positive, there is enough scope to expand or contract the project as needed. Importantly, it is “substantially within the sphere of information technology”.
Taking approaches from IT Systems Planning for Success (TM353) and an Agile approach from Software Engineering (TM354) meets the requirements. There is a substantial part of the application that needs synchronise with a server, utilising another level 3 module Developing Concurrent Distributed Systems (M362).
What I haven’t decided is the title!
Android Studio is a great development environment and is available on Ubuntu. I’m using Ubuntu Mate 16.10 “Yakkety Yak”.
First install a Java Development Kit (JDK). OpenJDK is pre-installed or you can use Oracle Java 8 (there is a great guide here). I don’t wish to argue over your choice – I need to use the latter (my tutor does). Download Android Studio here. – I extracted it to /opt; ran the installer; and used my home folder for the SDK. If you are using 64 bit, you need the 32 bit GNU standard C++ library:
sudo apt install lib32stdc++6
For Arch you need to enable “multilib” repository:
<code><span class="pln">sudo pacman </span><span class="pun">-</span><span class="typ">Syu</span> <span class="pun">&&</span><span class="pln"> sudo pacman </span><span class="pun">-</span><span class="pln">S multilib</span><span class="pun">/</span><span class="pln">lib32</span><span class="pun">-</span><span class="pln">libstdc</span><span class="pun">++</span><span class="lit">5</span><span class="pln"> multilib</span><span class="pun">/</span><span class="pln">lib32</span><span class="pun">-</span><span class="pln">zlib</span></code>
Virtualisation support is interesting. I read two tutorial and Google’s guide. The former makes reference to command line options not in version 2.2.2. These posts suggest this is a bug, but it may now be default behaviour. First enable that virtualisation in BIOS (check if enabled using “kvm-ok”).
sudo apt-get install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils
sudo adduser dougie kvm
sudo adduser dougie libvirtd
This results in an error.
Using the system version of libstdc++.so.6 works. Add the following to /etc/environment:
It seems snappy but with no feedback I’m unsure if accelerated.
So I now have a development environment set up for my project. The next hurdle is to choose a title. So far it is a: development project; distributed application; and uses Android.
Well I haven’t posted in ages but I’m down to a single TMA and two exams before I start the computing and IT project (TM470).
I’ve got what I think is a sound idea that builds on TT284, M362, TM353 and TM354 so fingers crossed. Its an integrated system developing an Android app, web app and a hardware solution that utilises near field communication (NFC) and is built on a Raspberry Pi B+.
So far my main issue has been getting back on top of Python. I haven’t used it since M269.
TT284 Web Technologies is a level two Open University module now in its second year of presentation and compulsory on the solutions development pathway of BSc (Hons) Computing and IT (B62). From the module description:
This course will give you an insight into architectures, protocols, standards, languages, tools and techniques; an understanding of approaches to more dynamic and mobile content; and demonstrate how you can analyse requirements, plan, design, implement and test a range of web applications.
Continue reading “Thoughts on Web Technologies (TT284)”
I got an invite from the Open University’s MCT department to try DreamSpark:
DreamSpark is a Microsoft Program that supports technical education by providing access to Microsoft software for learning, teaching and research purposes.
DreamSpark is simple: it’s all about giving students Microsoft professional-level developer and designer tools at no cost so that students can chase their dreams and create the next big breakthrough in technology – or just get a head start on their career.
Microsoft’s DreamSpark Website.
Its been quite useful. So far, I’ve tried Windows 8 and moved to a more recent version of Visual Studio. I recommend it, certainly if your University has an academic membership its worth asking for access because there is a significantly larger amount of software available.
This Christmas I’m going to embrace the past.
COmmon Business Oriented Language (COBOL) 85 standard was the first language I was taught. Napier University was a feeder into the banking and insurance industries in Edinburgh at the time and they had sizeable COBOL farms. It proved profitable too, as a number of students I knew went to the US to alleviate Y2K bugs in thousands of legacy applications. COBOL had fallen out of favour in US colleges.
Continue reading “Forget everything you knew about coding (or perhaps remember, depending on your age)”
Haven’t done much Project Euler recently – I’ve been busy studying. So here is an answer to problem eight which asks:
Find the greatest product of five consecutive digits in the 1000-digit number.
Continue reading “Largest product of five consecutive numbers in a 1000 digit number”
First TMA on MT264 (Designing applications with Visual Basic) got returned today – 96%. I’m very pleased with that and exceptionally lucky given that I read the material in a week, attended one on-line tutorial and wrote the assessment in a couple of days.
I’ve seen complaints on the module forum that tutors aren’t getting assessments back to quickly enough. The cut off was the 15th (I submitted on the 13th) and it was returned on the 27th, I don’t really see what the problem is.
Nested selection reared its head again but I didn’t lose any marks for it. In every programming module I’ve been picked up for using Else If so I played it safe and used nested If statements. So I was advised to use Else If proving I can’t win!
The sum of the primes below 10 is 2 + 3 + 5 + 7 = 17.
Find the sum of all the primes below two million.
Seemed pretty straight forward, loop through all numbers up to 2,000,000 – if they’re prime add them to a tally.
Dim beganAt As Date = Now
Dim n As Integer = 2000000
Dim total As Long = 0
For counter As Integer = 2 To n
If isPrime(counter) = True Then
total = total + counter
Dim endAt As Global.System.TimeSpan = Now.Subtract(beganAt)
Dim took As Integer = endAt.Milliseconds
Console.WriteLine(total.ToString + " in " + took.ToString + " ms.")
Private Function isPrime(ByVal thisNumber As Integer) As Boolean
' Prime numbers other than two are odd...
If thisNumber = 2 Then
ElseIf thisNumber Mod 2 = 0 Then
'Check it isn't divisible by up to its square root
'(consider n=(root n)(root n) as factors)
For counter As Integer = 3 To (Math.Sqrt(thisNumber)) Step 2
If thisNumber Mod counter = 0 Then
Just needed to be careful with data types – VB.Net’s Integer isn’t large enough so I changed to a Long. Gives 142,913,828,922 in 953 milliseconds.