Letters posted here are associated with the following Salon Premium Member:
Published Letters: 569
Editor's Choice: 61
...to put out a simple version of Basic.
However, it would be almost as easy for educators and textbook writers to put out their own version of Basic. Call it 'School Basic,' make it cross platform and free to download. Then all those textbook examples and those wonderful little programs that Scientific American used to put out can come alive again.
IOW, if we really want a universal programming language--and I think we do--then I think it's really up to the schools to maintain and develop it, exactly in the same way that schools maintain such universal languages as arithmetic and spelling. Companies just don't do arithmetic and spelling, no matter how much they depend on it, and it may be just as ludicrous to expect Microsoft to maintain Basic as it would be to expect that banks should teach people how to add, subtract, multiply and divide.
He wants a simple UNIVERSAL procederal programming language that EVERYONE can be conversant with and use.
He's talking about something on the level of arithmetic, not on the level of calculus or beyond. Something that is step by step and completely clear, something which teaches thinking, not computers or web page design. The other languages that people are mentioning are not at all suitable for this purpose.
This is written in a console app in Visual Basic Express, which is a really cool IDE and FREE to download from Microsoft.
'In the Monty Hall Game
'you are given three doors, behind
'one door is a brand new Cadillac,
'behind the other two doors are goats.
'You win the Cadillac if you can guess
'which door the car is behind.
'(You would rather win a Cadillac than a goat, wouldn't you?)
'Before opening the door you've picked,
'Monty Hall opens one of the other two doors
'and shows you a goat.
'Now there are two closed doors.
'Monty then gives you a choice;
'You can stay with your original pick
'Or you can switch to the other door.
'Now, what should you do?
'Most people assume the chances are equal either way.
'This program proves that you should switch doors
'because then your chances of winning the Cadillac
'will in fact be two out of three,
'as opposed to one out of three.
'
'--Believe it or not--
Sub Main()
'declare the values
Dim x, car, guess1, choice, WinStay, LoseStay, WinSwitch, LoseSwitch As Integer
Dim strinput As String
'seed the random generator
Randomize()
'loop 2000 times
For x = 1 To 2000
'pick a random number from one to three
car = CInt(Int((3 * Rnd()) + 1))
'this sets the door the car is behind
'pick another random number from one to three
guess1 = CInt(Int((3 * Rnd()) + 1))
'this is the player's first guess
'let's make the player chose to switch half the time
'this will give 1000 trials for each option
If (x Mod 2) = 0 Then
choice = 1
Else
choice = 2
End If
'now see who wins and collect results
If choice = 1 Then 'choice is to stay
If car = guess1 Then
'wins the cadillac
WinStay = WinStay + 1
Else
'loses and wins a goat - maybe
LoseStay = LoseStay + 1
End If
Else 'choice 2 to switch
'Hey, you know what? The door opening business
'doesn't make a damn bit of difference.
'It's a non-event that can't even be coded!
'The fact is, Switchers get to look in TWO doors!
'That's why switching should win two out of three times.
'So:
If car = guess1 Then
'shouldn't have switched
LoseSwitch = LoseSwitch + 1
Else
'the car was in one of the two other doors
WinSwitch = WinSwitch + 1
End If
End If
Next x
'stop looping and display results
Console.WriteLine(("Staying wins ") + CStr(WinStay) + (" times out of 1000 and loses ") + CStr(LoseStay) + (" times."))
Console.WriteLine(("Staying wins ") + CStr(WinSwitch) + (" times out of 1000 and loses ") + CStr(LoseSwitch) + (" times."))
'halt console so you can read results
strInput = UCase(Console.ReadLine())
End Sub
Note: there's nothing here about computers as such, nothing about 'popping the stack' or anything else. This is just an example of using coding to think through a problem. IMV, EVERYONE should be able to code like this. That's what Basic is good for, not to delve into computer basics, but to be a readily understandable and univeral programming language.
Programming, let us note, is something that is completely distinct from controlling computers. In fact, most people really don't want to know what is going on inside their computers and really don't need to know. But they should know how to program.
...was a patriarchy. The male head of a Roman family had life and death powers over everyone else in the family (which could include cousins, in laws, etc. Think of the Godfather).
Sweden is not a patriarchy. The US is not a patriarchy either. Whatever the problems of women in Western society, patriarchalism ain't it.
The use of the word patriarchy is one reason feminism keeps equaling silly in many people's minds. It's strident, overblown, and doesn't even make sense.
...when I saw her standing there....
...if winning is defined as Bush not losing.
If we pull out of Iraq, Bush will lose. It will become absolutely clear to everyone that the only thing that was accomplished by the invasion of Iraq was to hand Iraq over to Al Qaeda.
As long as Bush stays, he can convince at least some people that we might still win--never mind how. Hence Bush is determined not to pull out. If he never pulls out and the country never forces him to pull out, then that will amount to 'infinite time and infinite support,' at least as far as Bush is concerned.
I suppose we are all beyond shock by now, but this is, in fact, shocking. We are investing our national blood and treasure in an effort to keep George Bush from looking like a fool. Our national interest has now become equated with George Bush's personal interest. That makes George more like a tsar than a president.
...someone asked what tense that statement was in.
Future permanent. We'll never leave, thus we'll never lose.