Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (Darkly)
  • No Skin
Collapse

Chebucto Regional Softball Club

  1. Home
  2. Uncategorized
  3. Wanted: Advice from CS teachers
A forum for discussing and organizing recreational softball and baseball games and leagues in the greater Halifax area.

Wanted: Advice from CS teachers

Scheduled Pinned Locked Moved Uncategorized
233 Posts 143 Posters 0 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • myrmepropagandistF myrmepropagandist

    So Your Code Won't Run

    1. There *is* an error in your code. It's probably just a typo. You can find it by looking for it in a calm, systematic way.

    2. The error will make sense. It's not random. The computer does not "just hate you"

    3. Read the error message. The error message *tries* to help you, but it's just a computer so YOUR HUMAN INTELLIGENCE may be needed to find the real source of error.

    4. Every programmer makes errors. Great programmers can find and fix them.

    1/

    Jon QuassJ This user is from outside of this forum
    Jon QuassJ This user is from outside of this forum
    Jon Quass
    wrote last edited by
    #104

    @futurebird
    I've been a professional software engineer for over a decade now. I still make errors.

    What's interesting is that at a certain level it's possible to write code that in isolation works exactly as you want it to, but it doesn't work in combination with the rest of the existing code.

    But I also have tools to help me. My IDE checks for typos or syntax errors for me and flags them. It suggests solutions and offers to apply them. I have build tools written by other engineers to catch problems I might not have ever thought about.

    No one person knows everything, but anyone can learn enough to be effective

    1 Reply Last reply
    0
    • myrmepropagandistF myrmepropagandist

      Sometimes I have them write the code on paper with the computers closed. And this is fine, but I'd rather have them using the IDE or textedit and there is a limit to how much fun you can have with code on paper.

      And it does tend to be the weaker students who are almost happy to find something to stop the onslaught of information "see it doesn't work! we can't go on!" and that obviously makes me very grouchy.

      I need them to see this is like saying "Teacher my pencil broke! Stop the lesson!"

      ? Offline
      ? Offline
      Guest
      wrote last edited by
      #105

      @futurebird I have done some classes, explicitly saying I had not prepared anything, completed the exercises improvising there and then, made some mistakes of my own and corrected them. Showing that correcting yourself is part of the game.

      1 Reply Last reply
      0
      • ? Guest

        @futurebird Not a teacher, but that sounds great.

        Learning what error messages are and what they can tell you is so important. It's so different to many other subjects where you don't get that kind of information when something goes wrong, plus they will have grown up using computers of various kinds where an error message really is just a cryptic string of words that they can't do anything with.

        Iris Young (he/they/she) (PhD)I This user is from outside of this forum
        Iris Young (he/they/she) (PhD)I This user is from outside of this forum
        Iris Young (he/they/she) (PhD)
        wrote last edited by
        #106

        @phronetic @futurebird I can imagine a classroom where there's a running list of error messages encountered, and you get a sticker or bonus points or something for finding a new one, and explaining to the class what it means once you've figured it out. These days I can get an error message and approach it with "ooooohhhh never seen that before", but in my earlier years, hah!

        1 Reply Last reply
        0
        • myrmepropagandistF myrmepropagandist

          Wanted: Advice from CS teachers

          When teaching a group of students new to coding I've noticed that my students who are normally very good about not calling out during class will shout "it's not working!" the moment their code hits an error and fails to run. They want me to fix it right away. This makes for too many interruptions since I'm easy to nerd snipe in this way.

          I think I need to let them know that fixing errors that keep the code from running is literally what I'm trying to teach.

          Graham BinghamW This user is from outside of this forum
          Graham BinghamW This user is from outside of this forum
          Graham Bingham
          wrote last edited by
          #107

          @futurebird What a great set of discussions and thanks for being a teacher! (They pretty much make the world go round, imho.)

          I'm not one, but have taught some people coding over the years. Most recently I've seen that LLMs compound the problem you describe, because when the student has posted hundreds of lines of code to answer some fairly standard coding assignment, they have jumped so far into the deep end, that it's very hard for them to get out. The pasted code does all sorts of things they don't yet know about. Hopefully not your situation. Hopefully a lesson in its own right, but getting this young person to slow down and *do it themselves* was non-trivial.

          On a different tack, a project manager I knew once said energy project needs a project teddy bear. Any coding issues have to be explained to the bear first before getting senior help. The bear apparently solves 60%+ of the issues. Apocryphal, maybe.

          1 Reply Last reply
          0
          • ? Guest

            @RogerBW @futurebird (some) C coders have a saying:

            If the compiler emits an error, then your code can't run;

            If the compiler emits a warning, then your code won't run, at least not the way you expect it to;

            If the compiler emits no errors and no warnings, then it's high time you updated your compiler.

            Roger BW 😷R This user is from outside of this forum
            Roger BW 😷R This user is from outside of this forum
            Roger BW 😷
            wrote last edited by
            #108

            @aaribaud @futurebird When I moved from Perl to Rust as my primary language I was very pleased to find that whole classes of errors which had previously been runtime debugs turned into compile-time debugs. I am now an enthusiastic convert to strong typing.

            1 Reply Last reply
            0
            • myrmepropagandistF myrmepropagandist

              I think they become anxious when their code isn't working the same as what I have up on the projector and they want to get it fixed RIGHT AWAY so they won't fall behind.

              Then when one of them starts calling out they all do it.

              I may take some time to explain this.

              This never happens when I'm teaching math. Something about coding makes them forget some of their manners, and become less self-sufficient. "It's broke! I'm helpless!"

              What is that about?

              JavierJ This user is from outside of this forum
              JavierJ This user is from outside of this forum
              Javier
              wrote last edited by
              #109

              @futurebird when I bumped on that problem with my students, I made a lesson focused on:

              * provoking error messages
              * reading them, learning where in stacktraces is the info about them
              * correcting the error

              and categorizing them systematically: oh, NameError: this means I'm using a var that does not exist, maybe this is a typo here, or a typo there when I defined it.

              It helped them not panic when seeing errors and gave them tools to fix common ones on their own.

              1 Reply Last reply
              0
              • myrmepropagandistF myrmepropagandist

                Wanted: Advice from CS teachers

                When teaching a group of students new to coding I've noticed that my students who are normally very good about not calling out during class will shout "it's not working!" the moment their code hits an error and fails to run. They want me to fix it right away. This makes for too many interruptions since I'm easy to nerd snipe in this way.

                I think I need to let them know that fixing errors that keep the code from running is literally what I'm trying to teach.

                C This user is from outside of this forum
                C This user is from outside of this forum
                Coolcoder360
                wrote last edited by
                #110

                @futurebird not a teacher, so take with a cup of salt, but maybe having them not coding during your speaking parts could help?
                Like, locking their screens or all looking at you rather than typing at the machine.

                My guess is that anyone calling out like that got distracted with the coding and was not strictly paying attention to what was being said, so when they get the error, they may not see or hear anything aside from the error in front of them.

                1 Reply Last reply
                0
                • myrmepropagandistF myrmepropagandist

                  Wanted: Advice from CS teachers

                  When teaching a group of students new to coding I've noticed that my students who are normally very good about not calling out during class will shout "it's not working!" the moment their code hits an error and fails to run. They want me to fix it right away. This makes for too many interruptions since I'm easy to nerd snipe in this way.

                  I think I need to let them know that fixing errors that keep the code from running is literally what I'm trying to teach.

                  GhostOnTheHalfShellG This user is from outside of this forum
                  GhostOnTheHalfShellG This user is from outside of this forum
                  GhostOnTheHalfShell
                  wrote last edited by
                  #111

                  @futurebird

                  Present them or a piece of code and tell them this piece code has a problem with it and ask them to figure it out if you can find a fun thing all the better.

                  Have them perform a code review and look at code and say well figure out the failure modes of this piece of code.

                  I would actually have code refuse be part of your class.

                  1 Reply Last reply
                  0
                  • Linus GasserL Linus Gasser

                    @futurebird I'm also interested how to add LLMs to the mix: how to use them in a way we use IDEs now: we still know how to program/read code, but IDEs are so useful.

                    This will add another level to the me/them, where sometimes I'd want them to use LLMs, other times not.

                    But first I need to convince the school it's a good approach: I'm an external teacher, and as such have very little influence...

                    SemitonesS This user is from outside of this forum
                    SemitonesS This user is from outside of this forum
                    Semitones
                    wrote last edited by
                    #112

                    @ligasser @futurebird i'm interested, but very skeptical as well. Before the LLM craze, I was working through the CS50 Intro to CS class that Harvard offers online for free through OpenCourseWare. Even back then, they offered a rubber duck debugging program that you could type your questions to. And back then, I don't think it did anything except quack. But today, I would be curious what it does because I suspect they would try to use LLMs.

                    1 Reply Last reply
                    0
                    • myrmepropagandistF myrmepropagandist

                      My students aren't lazy, but they *can* be a little perfectionist: scared to take risks or sit with not having the answer right away.

                      They are really upset when their code won't run... but staying calm and *systematically* looking for the cause of the problem, knowing that if you just work through the tree of possible causes you will find it is not something they are good at.

                      I think I need to teach this.

                      Maybe I will give them some broken code and we will find the errors together.

                      ? Offline
                      ? Offline
                      Guest
                      wrote last edited by
                      #113

                      @futurebird
                      Teach The Ten Commandments of Egoless Programming. Especially "you are not your code" and "kindness to the coder, not the code"
                      Managed Coder: Advice to a New Programmer https://share.google/ahp9eb3GQvBOIfo8b

                      Teach paired programming, giving everyone a coding/debugging buddy. This is one of the most effective ways to level set coding standards and skills. Students learn from each other. It also prepares them for more public code reviews.

                      1 Reply Last reply
                      0
                      • Mans RM Mans R

                        @futurebird I know what you mean, and you're perfectly right when it comes to sane programming languages. However, C++ compilers have a habit of spewing out error messages the size of a Tolstoy novel in response to mistakes as trivial as a missing comma. Now I assume you're not teaching the kids C++ as that would be quite irresponsible.

                        SemitonesS This user is from outside of this forum
                        SemitonesS This user is from outside of this forum
                        Semitones
                        wrote last edited by
                        #114

                        @mansr @futurebird my highschool programming class was C++ based, but it was a joke. It was paint by numbers and we didn't learn programming.

                        The main thing I learned in that class was that Gmail existed and my classmates sent me an invitation to use it. Because he was checking his email during class time.

                        1 Reply Last reply
                        0
                        • ? Guest

                          @AbramKedge @futurebird I do this (in the context of a different academic subject) with "bad" essays, where we work collaboratively to find errors and redraft improvements. Hope it's effective for you.

                          SemitonesS This user is from outside of this forum
                          SemitonesS This user is from outside of this forum
                          Semitones
                          wrote last edited by
                          #115

                          @MintSpies @AbramKedge @futurebird when I was taking cartography classes our teacher would put up student work on the board but with the names removed and we would discuss it together. We didn't know if it was folks in our class or previous years and it was really helpful especially when you saw your own work up there and other people were kindly pointing out their suggestions.

                          1 Reply Last reply
                          0
                          • myrmepropagandistF myrmepropagandist

                            Wanted: Advice from CS teachers

                            When teaching a group of students new to coding I've noticed that my students who are normally very good about not calling out during class will shout "it's not working!" the moment their code hits an error and fails to run. They want me to fix it right away. This makes for too many interruptions since I'm easy to nerd snipe in this way.

                            I think I need to let them know that fixing errors that keep the code from running is literally what I'm trying to teach.

                            ? Offline
                            ? Offline
                            Guest
                            wrote last edited by
                            #116

                            @futurebird Are you familiar with the work of @Felienne ?

                            Link Preview Image
                            Over mij | About me

                            Nederlands Ik ben Felienne Hermans, hoogleraar didactiek van de informatica aan de Vrije Universiteit Amsterdam, en leraar informatica op de Open Schoolgemeenschap Bijlmer. Aan de VU geef ik de vakken Vakdidactiek Informatica en AI in het Onderwijs, en doe ik onderzoek naar de toegankelijkheid van de digitale wereld in brede

                            favicon

                            Felienne (www.felienne.nl)

                            1 Reply Last reply
                            0
                            • myrmepropagandistF myrmepropagandist

                              Wanted: Advice from CS teachers

                              When teaching a group of students new to coding I've noticed that my students who are normally very good about not calling out during class will shout "it's not working!" the moment their code hits an error and fails to run. They want me to fix it right away. This makes for too many interruptions since I'm easy to nerd snipe in this way.

                              I think I need to let them know that fixing errors that keep the code from running is literally what I'm trying to teach.

                              That Dinkum ThinkumB This user is from outside of this forum
                              That Dinkum ThinkumB This user is from outside of this forum
                              That Dinkum Thinkum
                              wrote last edited by
                              #117

                              @futurebird
                              I teach physics, but I know what you mean. I usually start by saying that 500 years ago ppl. like Leonardo da Vinci would easily have understood how the (classical) physics of a modern car works, but they would never have believed we could manufacture the parts with such precision. So the class is more about error control than new concepts.

                              I also remember it being quite a mental leap for me as a student.

                              1 Reply Last reply
                              0
                              • Dave Ames 🟨🟥D Dave Ames 🟨🟥

                                @futurebird have a look at some of the stuff Phill Bagge wrote about Learnt Helplessness https://philbagge.blogspot.com/2015/02/eight-steps-to-promote-problem-solving.html?m=1 and ways to work around it. I remember him doing lots of related work on it about 10 years ago.

                                Iris Young (he/they/she) (PhD)I This user is from outside of this forum
                                Iris Young (he/they/she) (PhD)I This user is from outside of this forum
                                Iris Young (he/they/she) (PhD)
                                wrote last edited by
                                #118

                                @DavidAmes @futurebird note however that the term is misused here (and elsewhere) -- learned helplessness is a clinical term describing people no longer attempting things that have previously gotten them punished (usually physically hurt), even if that response is no longer present. https://en.wikipedia.org/wiki/Learned_helplessness This is often an explanation for seemingly illogical behavior in people who've endured abuse, and it's frustrating that the word is now being used to shame people for exhibiting the behavior! I point this out not as a criticism of the blog piece but in hopes that we use different terms going forward.

                                1 Reply Last reply
                                0
                                • ? Guest

                                  @futurebird "This never happens when I'm teaching math. Something about coding makes them forget some of their manners"

                                  My take -- it's GOAL-ORIENTED. Maths is modelling, descriptive. Δ🧠-states

                                  SemitonesS This user is from outside of this forum
                                  SemitonesS This user is from outside of this forum
                                  Semitones
                                  wrote last edited by
                                  #119

                                  @wavesculptor @futurebird what does change in brain states mean in this context?

                                  ? 1 Reply Last reply
                                  0
                                  • myrmepropagandistF myrmepropagandist

                                    @freequaybuoy

                                    "I have the exact same thing as you but it's not working"

                                    99 times out of 100 no, no you do not have the "exact same thing" you've made a typo.

                                    Because the whole point of it being a computer is that if you have the exact same code it always does the exact same things.

                                    SemitonesS This user is from outside of this forum
                                    SemitonesS This user is from outside of this forum
                                    Semitones
                                    wrote last edited by
                                    #120

                                    @futurebird @freequaybuoy "works for me/on my machine"

                                    1 Reply Last reply
                                    0
                                    • myrmepropagandistF myrmepropagandist

                                      Wanted: Advice from CS teachers

                                      When teaching a group of students new to coding I've noticed that my students who are normally very good about not calling out during class will shout "it's not working!" the moment their code hits an error and fails to run. They want me to fix it right away. This makes for too many interruptions since I'm easy to nerd snipe in this way.

                                      I think I need to let them know that fixing errors that keep the code from running is literally what I'm trying to teach.

                                      ? Offline
                                      ? Offline
                                      Guest
                                      wrote last edited by
                                      #121

                                      @futurebird I think someone else already mentioned teaching it backwards.

                                      Start with working code - a small program that fits on a page, it doesn't really matter what it does.

                                      Then give them the same code with a single syntax error - tell them it's broken and have them discover what the issue is. Keep going until they can find most of the problems easily, by looking at the error messages.

                                      Teaching programming is damned hard in a classroom setting - I'm old enough to have learned programming in uni, and class time was for lectures, homework was the programming (in a lab where you could get help).

                                      After they are good at syntax errors, move on to bug hunting.

                                      I know, it sounds boring, but I am sure you can come up with some kind of ant related game to make it fun 😉

                                      We need a new way to teach programming because many of the existing methods don't work. Or we need to understand why it doesn't work with school age kids and whether we should be teaching them programming instead of something else

                                      1 Reply Last reply
                                      0
                                      • myrmepropagandistF myrmepropagandist

                                        Wanted: Advice from CS teachers

                                        When teaching a group of students new to coding I've noticed that my students who are normally very good about not calling out during class will shout "it's not working!" the moment their code hits an error and fails to run. They want me to fix it right away. This makes for too many interruptions since I'm easy to nerd snipe in this way.

                                        I think I need to let them know that fixing errors that keep the code from running is literally what I'm trying to teach.

                                        Butch Hattrick ⚧️R This user is from outside of this forum
                                        Butch Hattrick ⚧️R This user is from outside of this forum
                                        Butch Hattrick ⚧️
                                        wrote last edited by
                                        #122

                                        @futurebird back in 1984, during my first computer class in high school, I can totally recall all of us students being the exact same way. Only difference was, the teacher would say "questions at the end" or ignore people calling out, and just get on with the entire lesson. Seriously.

                                        And when it came to the walking around part, all you got was questions about what you were trying to do, or questions to make you think, you NEVER got the work done for you.

                                        That was actually a fun teacher.

                                        1 Reply Last reply
                                        0
                                        • hoertaufH hoertauf

                                          @futurebird You probably already know @b0rk‘s Pocked Guide to Debugging. The thing I love so much about it is how she cherishes the bug, instead of squashing it (in the illustrations too). I love this attitude. Not sure if students can learn to think that way? There is a beautiful poster too:

                                          📰 https://wizardzines.com/zines/debugging-guide/

                                          🖼️ https://store.wizardzines.com/products/poster-debugging-manifesto

                                          ? Offline
                                          ? Offline
                                          Guest
                                          wrote last edited by
                                          #123

                                          @hoertauf @futurebird @b0rk +1 for pretty much anything by Julia Evans.

                                          1 Reply Last reply
                                          0

                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • 1
                                          • 2
                                          • 3
                                          • 4
                                          • 5
                                          • 6
                                          • 7
                                          • 8
                                          • 11
                                          • 12
                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          Powered by NodeBB Contributors
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups