Computer Science Teacher
Computer Science Teacher - Thoughts and Information from Alfred Thompson

September, 2011

  • Computer Science Teacher - Thoughts and Information from Alfred Thompson

    Readability in Programming Languages

    • 37 Comments

    I saw a side by side comparison of a bunch of scripting languages online recently. Scripting Languages: PHP, Perl, Python, Ruby My first, and second reaction was yuck! Now I have my biases – biases which may  not be shared by others of course. But I like readable code and for me anytime I see a special character (anything not an alphanumeric) it slows me down. This got me thinking about where we are going in design of programming languages? Are we moving forward (what ever that means) or backwards or just sideways?

    Back when I started programming close to 40 years ago the big three programming languages were FORTRAN and COBOL with an up an coming language called BASIC. FORTRAN (short for FORmula TRANSlation) was used by mathematicians (my math major brother had to learn it) and scientists. COBOL (the B stands for Business) was used for business applications. BASIC was a teaching/Learning language that was spreading into business. COBOL was both loved and hated by different people for its wordiness. But it was at least understandable. Take the loop below:

    PERFORM VARYING WS-BOTTLE-NUM FROM 98 BY -1
                   UNTIL WS-BOTTLE-NUM < 2
    END-PERFORM

    Pretty close to an English sentence. Compare that to this sample for a C-style language (C#)

    for (WSBOTTLENUM = 98; WSBOTTLENUM >= 2; WSBOTTLENUM--)
    {
    }

    Which one is more obvious? Pretend you are not an experienced programmer.

    BASIC (Visual Basic in this case) is somewhere in the middle.

    For WSBOTTLENUM = 98 To 1 Step -1
     
    Next

    The step – the counting down – is more easily understandable for me at least. Now let’s take a look at something very simple. k = i / 10;

    This drives beginners crazy. What’s going on here? Sure we programmers know but a lot of beginners struggle with which direction the operation is going. Compare that to the same code in COBOL

    divide i by 10 giving k

    Wordy? Sure, but at least even a beginner can read it. Now I am not arguing that we should all go back to COBOL though honestly with modern IDEs and features like Intellisence it would be a lot easier than it was back when I was typing out punch cards. Rather I am suggesting that beginner languages can and probably should be more wordy rather than more obscure – that English is easier to pick up than “what does # in this programming language mean?”

    Just for fun, if you want to see what different programming languages really look like visit the 99 Bottles of Beer site.

    This Website holds a collection of the Song 99 Bottles of Beer programmed in different programming languages. Actually the song is represented in 1434 different programming languages and variations.

    Somewhat related posts:


  • Computer Science Teacher - Thoughts and Information from Alfred Thompson

    Computer Science Education Act

    • 0 Comments

    One of the big issues with computer science education is that it is not an integral part of the curriculum It is almost always an elective and doesn’t count as meeting specific graduation requirements. And then there is the whole issue of lack of teacher certification standards and standard curriculum. About the only standard in education is the Advanced Placement curriculum and it is far from universally accessible. It looks like a couple of members of Congress are trying to address these issues. (From Robert P. Casey Jr. | United States Senator for Pennsylvania: Newsroom – Press Releases.)

    U.S. Senator Bob Casey (D-PA) and Congressman Jared Polis (D-CO) today introduced the Computer Science Education Act, which will help prepare Americans for the more than 1.5 million high-wage computing jobs that are expected to be created in the U.S. by 2018. The bill will help states to increase and strengthen their computer science offerings in K-12 education.

    To reverse these troubling trends and prepare Americans for jobs in this high-wage, high-growth field, the Computer Science Education Act will:

    • Ensure computer science offerings are an integral part of the curriculum;
    • Develop state computer science standards, curriculum, and assessments;
    • Improve access to underserved populations;
    • Create professional development and teacher certification initiatives, including computer science teacher preparation programs in higher education;
    • Form a commission on computer science education to bring states together to address the computer science teacher certification crisis; and,
    • Establish an independent, rigorous evaluation of state efforts with reporting back to Congress and the administration.

    It sounds good. I haven’t read the bill yet as it doesn’t seem to be in the Library of Congress Thomas database yet so I’m not ready to endorse the specifics of course. But I do like the sounds of what I read on Sen. Casey’s press release. There is no telling how far a bill like this well go and even if it passes it may be very different by that time. But at least some in Congress are aware of the issue and trying to do something about it. A while back we saw Computer Science Education Week get Congressional support. Another step in the right direction though it is too early to see how much difference that makes. CS Ed Week doesn’t force or even incent states to solve the issues we see in Computer Science Education though. When ever you force people to do anything, no matter how good it is for them, there is resistance. IF this bill starts some conversations that would be a good start. We’ll have to see where it goes from here.

    EDIT: You can read the bill at http://polis.house.gov/UploadedFiles/Bill_Text_-_Computer_Science_Education_Act.pdf



  • Computer Science Teacher - Thoughts and Information from Alfred Thompson

    Windows Phone Mango Jump Start Workshop Now On Video

    • 0 Comments

    IF you missed it live (like I did) you can now view the recording of the Windows Phone Mango Jump Start training on Channel 9. I borrowed these direct links from the official announcement.

    Microsoft MVPs Rob Miles and Andy Wigley are back! The "Building Applications for Windows Phone "Mango" Jump Start" was hosted by Microsoft Learning as a follow-up to last year's Windows Phone 7 Jump Start sessions. Mobile application developers rave about the fast-paced, demo-rich, real-world and often-times humorous approach Rob and Andy use to deliver this timely content. Now that "Mango" has made such a huge splash in the industry, we've asked them to put together another great course.

    1. Mango Jump Start (01): Building Windows Phone Apps with Visual Studio 2010 
    2. Mango Jump Start (02): Silverlight on Windows Phone—Introduction
    3. Mango Jump Start (03): Silverlight on Windows Phone—Advanced
    4. Mango Jump Start (04): Using Expression to Build Windows Phone Interfaces
    5. Mango Jump Start (05): Windows Phone Fast Application Switching
    6. Mango Jump Start (06): Windows Phone Multi-tasking & Background Tasks
    7. Mango Jump Start (07): Using Windows Phone Resources (Bing Maps, Camera, etc.)
    8. Mango Jump Start (08a): Application Data Storage on Windows Phone | Part 1
    9. Mango Jump Start (08b): Application Data Storage on Windows Phone | Part 2
    10. Mango Jump Start (09): Using Networks with Windows Phone
    11. Mango Jump Start (10): Tiles & Notifications on Windows Phone
    12. Mango Jump Start (11a): XNA for Windows Phone | Part 1
    13. Mango Jump Start (11b): XNA for Windows Phone | Part 2
    14. Mango Jump Start (12): Selling a Windows Phone Application
Page 1 of 6 (17 items) 12345»