Who has been given the cash changing problem?


Some class, somewhere, has obviously been given the recursive money changing problem as a piece of work, because I have had several hundred visits in the last week from people seeking to get a grip on it.

Here’s the best solution, either buy Structure and Interpretation of Computer Programs or simply read it for free online.

Advertisements

A (partial) reply to @pootblog


This has been sitting around for a few days now, because I don’t really want to have a flame war with someone I like, but here goes anyway…

Damian Counsell (@pootblog) objected to what I wrote about grammar schools, so I thought I’d do a proper reply. His comments in italics.

Those 75% of students—sorry: “victims”—”thrown on the scrapheap” in Northern Ireland still subsequently outperform their matched peers in comprehensive schools on the mainland. I’m tired of reading this cliché—this lie—every time the question of school education policy in these islands comes up for the usual evidence-lite discussion; though it’s understandable that it should proliferate as rigour and hard science have been drained from the secondary curriculum by the same ideologues who’ve brought us selection-by-house-price.

Firstly, if not directly related to the matter in hand, Britain is not “the mainland” – that begins at Calais.

The claim here is that it is a “lie” that those in Northern Ireland who failed the 11+ still did better at school than those in comprehensives (presumably Damian means the same three quartiles) in Britain. Now, I could simply say I was writing about Catholics in the mid-1970s (because I was) and say that it’s an open-and-shut case – Catholics who failed the 11+ did spectacularly badly at school (today the religious position is somewhat reversed, which is more evidence of how working class protestants are being systematically failed by their political ‘leaders’ – but that’s another story). But actually the problem was a more general one:

The final figure (figure 6.4) of this section looks at the relative extent of unqualified school leavers in both religious school systems. This is a particular problem in Northern Ireland where the proportion of pupils leaving school with no O Level or CSE qualifications, of any kind, has been and remains higher than in Britain as a whole: in 1986/7, for example, 21.9% of Northern Ireland school leavers had no GCE/CSE qualifications compared with 9.6% of leavers in England and 16.1% of leavers in Wales.

(From here. Sounds like being thrown on the scrapheap to me – if we assume all or almost all these school leavers were from “secondary schools” – as they are called in Northern Ireland – then that indicates around 30% of pupils entering those schools left with no CSEs or O levels at all.)

NB: A crucial change since then has been the “comprehensivisation” of the exam system. The old CSE/CGE divide essentially wrote off those who took CSEs even before they got started – for while a CSE Grade 1 was an equivalent of an ‘O’ level C grade (ie a pass), the mere fact that a pupil had been entered for a CSE was a signal that they were not seen as a strong performer.

Since that time Northern Ireland’s pupils have closed the gap significantly at the bottom end – though 21.7% of Northern Ireland’s workforce still had no qualifications, compared to 13.2% of England’s – and in 2005/6 3.1% of pupils in Northern Ireland got no graded results whereas the figure for England was 2.2% – figures from Regional Trends 2008.

Understandably, you still haven’t addressed my central point, which is that the claim that 75% of kids end up on the “scrapheap”, however generously you interpret that metaphor, is simply false. I’ll say it again: under the comprehensive system, kids from the same backgrounds do worse than they would do at secondary moderns. The dogma of comprehensivisation is up there with Lysenkoism in the pantheon of systematic, ideologically motivated establishment lying.

Damian did not produce any figures and I have: to repeat, I was writing about the mid-1970s when the figures were truly appalling. Even today the figures show that selective education is producing half as many again kids with no qualifications in Northern Ireland as in England (where comprehensive education dominates) and that the full cohort of adults in Northern Ireland includes a huge excess, in comparison to England, of people with no qualifications at all.

Obviously there’s no way to test the counterfactual, but I wouldn’t be even slightly surprised if the advent of the comprehensive school in system in England and Wales led to significant numbers of children who might otherwise have led happier lives growing up to be convicted criminals; but I’m not going to overplay my hand here; you’re right: unlike Lysenkoism, it’s unlikely anyone died of starvation. Let’s just say that—even if it resembled reality in any way at all—your talk of human beings being “thrown on a scrapheap” isn’t exactly measured language either. And that’s where I came in.

One thing that *isn’t* a counterfactual is my central contention. Again, you deliberately avoid the point. I’m not saying that kids “*would* do better at secondary moderns”; I’m saying that kids *do* do better. It’s the biggest side-by-side comparison in secondary education and ideologues deliberately ignore the overall result; just as they ignore the results when vouchers are shown to help poor and black pupils in the only randomised trials in education I’ve ever read about.

Kent is neither here nor there: it’s one artificial island of selection set in a sea of mixed-ability, LEA-controlled state schooling, so the effect of selection-by-house price is doubled down. Of course kids in secondary moderns there are going to do badly—if indeed they do: you haven’t actually cited a substantive result in that case either.

Well, where is the evidence that kids do better at secondary moderns then? I understand the point about black pupils – but no evidence has been offered here for the central claim. If Damian has some evidence to back up his point I’d love to see it. My point about Kent is that in that county – where selective education dominated until quite recently (thanks to the Labour government some of the secondary moderns have now become ‘academies’ and so the position is changing though maybe not that much), there is a high proportion of failing schools: look at this table, for instance. This blog and map suggests to me that Kent is also letting a lot of its kids down.

I freely concede that the religious divide in Northern Ireland had, and continues to have, terrible effects. Catholic kids are and have been simply worse-off on average. That’s a fact, and that wasn’t what I was engaging with either.

I was simply attacking one tired, hyperbolic, clichéd untruth that appears over and over again in such discussions. It keeps being trotted out because no right-thinking person dares to challenge it. The burden of proof here doesn’t lie with me; it has always rested with the social engineers. (If only they had a tiny fraction of the rigour of most actual engineers!) It’s a measure of how polluted the ground has become that you and others can repeat this outrageous myth and throw up chaff when asked to back it up with anything other than personal anecdote.

And, yet again, for the avoidance of doubt: I am not advocating a return to the grammar/secondary modern divide. I just want discussions about education to be based on evidence, not dogma and tribal boilerplate.

And, this is subjective so maybe will not pass Damian’s test, but the idea that the 11+ was in some way more “equitable” than “selection by house price” (which I freely concede is a big factor) is also nonsense. In the mid-1970s West Belfast was one of the most concentrated islands of deprivation in Northern Europe, but as is the way with ghettos, we middle class kids were in there with everybody else. Of my primary school class of about 28 (all boys), 5 of us passed the “qually”. Gary, Tony and I were from middle class backgrounds, Michael and Liam were not. Liam refused to go to a grammar school as all his brothers had gone to De La Salle school (on his street) and he was not going to be different: so three quarters of the grammar school boys were middle class from a cohort where I’d guess to close to 50% of the boys were on free school meals.

Shoe laces and psychopathy


When I think back to my time in the mid-1970s at Holy Child Primary School in Andersonstown in West Belfast I often conclude that the principal qualification for teaching most staff there had was either a hatred of children or a psychopathic desire to do them physical and mental harm. (I am not joking by the way).

English: The Andersonstown Road This road is c...
English: The Andersonstown Road This road is constantly busy with shoppers, churchgoers and cars. It is the route of choice for people travelling to and from Twinbrook and Poleglass. The floodlights of 443977 can be seen in the top right of the picture. (Photo credit: Wikipedia)

Children were hit for any reason, or indeed no reason at all. Once a female teacher dragged me off the ground for a good ten metres by hair alone. My crime was to have, at a school sports day at Casement Park, to have got out of my seat to have congratulated a school mate. No circle of hell is hot enough for people who treat 9 year olds in this way.

(Of course, at the age of 11 the system then went on to throw 75% of its victims on the scrapheap via the 11+ exam. I passed that and went on grammar school, one of the lucky ones. But I remember the waste of talent and the brutality of the system well enough to regard those who think it was some sort of golden age of order and social mobility with a mixture of pity and contempt.)

One of the little scams of our teachers – all of them, not just mine – was to naff off to the staff room for a cup of tea and a cigarette at morning break time having set us some work. The idea that the point of the break was to let the kids out into the playground seemingly never occurred. School was not for our benefit, after all. Failure to do the work, or to have done it badly would quite often result in a beating.

So one day my P6 teacher decided that the task we would all have to do was to write-up on how to tie our shoelaces (as you can see the task was predicated on the need for the teacher to have to make the minimal amount of  preparation – sometimes we were simply told to copy out passages of school books). In truth, I did not know how to do this and the task caused more than a little panic. Frantically, experimenting and desperate, I managed to get it done.

And, whatever the reason, the way I learned to tie my shoe laces is, it would appear, the correct way.

When I read this column in the Guardian last night I thought the opposite, and so this morning tied one shoe in the way I have always done (at least since that day in 1976) and one in what I thought, from having read the linked website, was the “correct” way. Needless to say, after about half an hour of walking the shoelace on the “correctly” tied shoe was coming loose and that on the “traditional” side was still firmly fixed.

How to destroy our science base


York University LibraryThis is a first (for me) – writing a blog inside a university library – photographic evidence attached.

Term does not start for another fortnight – Freshers’ Week is next week – and so there are not that many of us in the library. Of those of us here I’d guess about 50%, perhaps more, are East Asian.

This is not a “yellow peril” story about how they’re-all-over-here-taking-our-university-places, but a reminder of how, despite the best efforts of the current UK coalition government, many thousands of overseas students still look to the UK as a centre of educational excellence.

Indeed our universities may be our most successful export industry of all.

Much more than just the financial health of the universities depends on keeping the UK’s reputation as a good place for overseas students: because if we damage the universities we will rot our science base, corrode our schools and trash any hopes that the current period of economic mid-winter can ever be replaced by sunnier times.

A few weeks ago “Sir” Andrew Green, rentagob for shady anti-immigration outfit “Migration Watch” – beloved of the broadcasters because its acceptable to put them on and not open racists and “Enoch was right” nutters – more or less admitted on the Today Programme that the only basis on which to oppose foreign students coming to Britain was because you don’t like foreigners much. He certainly accepted that student migration to the UK was of economic benefit. It’s about time a few more voices from the business and political establishment had the courage to tell Green and his ilk that they might want to condemn the country to long term economic misery and decline but they do not.

A lot of politicians feel that dealing with race is all too difficult and some even lurch towards the Gordon Brown mess of rhetoric that borders on the offensive – “British jobs for British workers” – in the hope that will divert attention from the real policy of having an open, trading, economy. Well, I know it is not easy to win the arguments but that is not an excuse for not trying. Personally I believe that it is possible to win an argument for an open economy with high levels of migration, matched with effective immigration controls. And I believe that because I saw Tony Blair do it, at close quarters, in the 2005 general election campaign.  In any case, when it comes to bigotry politicians must realise they are fighting a bear and give up when the bear gets tired, not when they are.

Not a proof that aleph null and the order of the continuum are the same


Cantor's diagonal arguement
Cantor’s diagonal arguement (Photo credit: Wikipedia)

One final point from Wheels, Life and Other Mathematical Amusements– this time a “non-proof”.

Some argue that the order of the counting numbers, \aleph_0 is the same as that of the continuum – in other words that there is no difference in the scale of these two infinities.

Here is an argument that is sometimes advanced in this way, I found it initially seductive, but the proof it is wrong is actually very simple.

We simple assign an integer to every member of the continuum by “reversing” its order so, for instance:

1        0.1
2        0.2
3        0.3
4        0.4
5        0.5
6        0.6
7        0.7
8        0.8
9        0.9
10      0.01
11       0.11

100    0.001
101     0.101

And so on…

So what is the proof that this isn’t a proof that destroys Georg Cantor‘s work and rocks modern mathematics to its foundations? Well, in essence it is a restatement, in a slightly different way, of our old friend the diagonalisation argument.

No matter how long this list goes on for no number on the left hand side will ever have \aleph_0 digits. Hence no number on the right will ever represent an irrational. Hence it is impossible to assign a counting number to all the members of the set of the continuum.

Think of \frac{1}{3} – there could never be enough counting numbers to represent this as a decimal, as there will always be another 3 to add on at the end…

Don’t think about it too hard, though, as it bends the mind!

Subsets of the continuum


example of an picture environment in in LaTeX,...
(Photo credit: Wikipedia)

Following on from the discussion of the set of all the integers, with order \aleph_0, and the set of all its subsets– the continuum, of order c with c = 2^{\aleph_0} – what can we say about the set of all subsets of the continuum?

Like any other set of order N we can say it has order 2^N , in this case 2^c or 2^{2^{\aleph_0}}. But what do its members represent in the physical world?

By interleaving digits each point on the continuum can also be thought of as a representation of cartesian co-ordinates: for instance 0.55011200…. can be thought of as (0.5010…, 0.5120…) using interleaving, so we can think of a subset of the continuum as a subset of points on the cartesian plane and all the subsets as all the possible curves in the cartesian plane (including disjoint curves).

According to Wheels, Life and Other Mathematical Amusements– the book is a good thirty years old so I am hedging it here a bit – there are no known physical representations of yet higher transfinite orders – they exist in a purely mathematical world: discussion of the philosophical implications of which is fascinating but beyond me.

Another way of looking at the alephs


English: Georg Cantor
English: Georg Cantor (Photo credit: Wikipedia)

This is another insight gained from Wheels, Life and Other Mathematical Amusements– this time about the transfinite numbers.

The smallest transfinite number, so -called \aleph_0 is that of the countable infinity, or the counting numbers (the integers). Start at 1 (or 0) and keep going.

But how many sets can one make from the counting numbers? Well we know that for a set with n members there are 2^n possible subsets including the empty set \emptyset and the original set itself. Therefore we have 2^{\aleph_0} subsets of the integers.

So how big is 2^{\aleph_0}? The same size as the continuum, Georg Cantor‘s hypothesised \aleph_1 (i.e., the next biggest transfinite number) – though this hypothesis has never been proved and work continues on demonstrating there is a smaller transfinite number between \aleph_0 and the cardinality of the continuum.

Normally one sees the continuum explained as uncountable via the “diagonalisation argument” but the book makes a slightly different, if ultimately equivalent proof via contradiction:

Take all the subsets and assign an integer to each one.

If the integer is assigned to the subset containing the integer  which it has been assigned then label it ‘blue’, if the integer is assigned to a subset it does not contain then label it ‘red’.

So all the red integers themselves form a subset of the original set, can it be matched to a blue integer? No because then it would match to a subset that contained the integer, but as its red it cannot.

So can it then be matched with a red element? No because then a red element would be matched with a red element and should therefore be blue … a contradiction.

If you think about this for a bit you will also see it is directly equivalent to the diagonalisation argument and thus the cardinality of the subsets of the countable numbers is the same as that of the continuum.

‘O’ levels versus GCSEs


I have 11 ‘O’ and 2 ‘Advanced Ordinary’ (AO) GCEs to my name, so I reckon I was in the upper decile of that exam system before it was replaced by the GCSE.

GCE Certificate - History Ordinary
GCE Certificate – History Ordinary (Photo credit: Leo Reynolds)

But I have no love for it and the proposal that it or something like it should be brought back is populist pose-striking.

The argument seems to be that a GCSE course is modular and involves coursework it is less rigorous than an exam-only qualification (like the ‘O’ level).

Presumably all holders of masters degrees and doctorates should now regard their qualifications – based on rigour-lacking ‘coursework’ – as worthless?

Michael Gove, the education secretary, has his bachelor’s degree from Oxford – where one simply buys a master’s degree: so perhaps he’s mistaken that ‘qualification’, if he has it, for a real one?

Exam-only qualifications are poor preparation for university in any case, where all degrees are modular and re-sits (another supposed crime of the GCSE) are common.

The hidden agenda here, though, seems to be to replace a standards-based qualification – ie where the GCSE measures if one has reached a certain proficiency in a subject – with a normative based one – in other words only a fixed percentage being able to pass or reach a given grade. In that sense this would be a worse option than the ‘O’ level, where one’s proficiency was being measured.

Most people are worried – rightly – that the move may be a cover to reintroduce the two-tier exam system that the GCSE replaced. Then lesser mortals were set the CSE exam which, despite its top grade being an equivalent to the GCE, marked them out as ‘failures’ regardless of their results. Bringing that or anything like it back would be hugely regressive: but I do not think even Gove is that stupid given the massive negative reaction when he floated just such an idea. But justified relief at this should not be allowed to obscure the other nasties in the package.

Weasel words from the DWP on Universal Credit?


English: This poster provides a good visual of...
English: This poster provides a good visual of the standard Agile Software Development methodology. (Photo credit: Wikipedia)

Britain is once more being an IT pioneer, with the world’s biggest “agile” software development project – for the Universal Credit that will, the law states, replace a myriad of different state benefits in the autumn of 2013.

If you know anything about software development the above sentence ought to make you feel, at the least, a bit nervous because what it is telling you is that the livelihoods of millions of the most vulnerable people are in the hands of a software experiment running to an extremely tight deadline.

Agile methods have been developed to counter some of the traditional failings of software development, which often occur because of a failure to understand the requirements of the client, and centre on the idea of handing the client repeated builds of the product for testing, feedback and refinement.

So when the Department of Work and Pensions say, as they have done today, that

the majority of Universal Credit IT systems had already been built and were being tested.

Then their words could mean next to nothing – the idea with agile is to build as quickly as possible and test as much as possible. But what could be being tested could be close to useless.

Of course, I could be wrong. Maybe the whole system is all but completed, a multi-billion software project could be about to be delivered on time and on budget using experimental methods and at a scale never before seen. If it happens it will make Britain’s software houses the world’s leaders, in demand from all corners.