How to recast an ASPX application as Object Oriented I am a programmer in a small department creating some new tools and applications with ASPX and SQL, and explaining the methodology to co-workers, and writing documentation (so the question here qualifies as 'teaching'). Having programmed for 30 years and many times created particular systems of multiple connected parts, I think that OOP is probably not the big deal we make of it, but I would like to know how I could have designed the system described below in a more Object Oriented way - to recast it if needed and move forward with more explainable projects in the future.

In brief, the "File Cabinet" system I created recently is to facilitate recreating the intranet used by hundreds of people where I work. The intranet consists of many thousands of files and links to internal and external pages, programs and tools. The File Cabinet idea says that there are two basic ways to show links on the intranet and allow authorized users to make changes, instead of asking the web maintainer to make every single change for them. The two ways are:

Present a folder in the OS as a set of links to files and folders. Users make changes by placing new files in the appropriate place in the filesystem. This display method duplicates some Windows Explorer functionality in a web page.
Provide a method where authorized users can maintain sets of 'Sections' on a Page containing a list of links in each section. The entire page would render just by reading an SQL table listing the sections, and an SQL table listing the links in each section. Users can add and change links and upload files if necessary.

I have it working. The appearance can be customized using a CSS file. The two methods of seeing the content look the same to normal users. Users who can maintain the site already know how to move files around, and can be shown how to use the Editable Links method. These two methods should dramatically reduce the effort of recreating the department's intranet.

I used ASPX to define data sources (SQL or the OS filesystem) and ListViews to generate an HTML table or a set of nesting HTML div's to render the content. The code-behind is VB.Net and most of it is just responding to clicks, manipulating the data before presentation and so on.

Could this project have been built in an Object Oriented manner? I think that most of the applications I create, particularly for our department's intranet, are not really amenable to OO, because they basically consist of only a data source and rendering method. The complexity has to do with manipulating data as it passes between the source and screen.

Is this "too simple" for OO? Or just a different kind of situation? Are web applications usually designed with objects?

The object-oriented and procedural, or imperative, paradigms, and the functional, logical and mathematical, or declarative, paradigms are just that "paradigms." They are the embodiment of thought patterns and methods for modeling solutions. So long as the end result of a paradigm, the language used to implement it, is Turing complete, and the associated hardware can handle the needed elements, a solution that can be developed in one paradigm can usually be reproduced in another.

The issue shifts from "can it be done this way?" to "is this a satisfactory way to do it?" Some problems are better suited to one method while other are easier to solve using a different method. Using any paradigm to solve a problem, or implement a system, requires the ability to "think" within the model which the paradigm embodies.

I don't think it is fair to classify any practical solution as too simple, or too complex, for any given paradigm. Especially within the education arena, where the goal is learning how to employ the paradigm, and most "problems" are structured to meet educational objectives more than "real-world" problems.

As an "example" for future projects, the described system might even be too large for the students to apprehend while also trying to learn the basics it employs. If it had a smaller scale to it, the project could model several different paradigms in concert. Web applications are commonly developed using the MVC architectural pattern. The handling of the data (model of MVC) could be accomplished using a functional language, the HTML/JavaScript/CSS (the view of MVC) can be implemented well with procedural, non OO programming. The OO programming can be done in the system which gathers the data, and adjusts it according to the directives from the user.

However it's done, the hardest part will likely be converting something you know well, done in the paradigm you are most comfortable with, into something you don't have as much practice with, using a paradigm which is, for all practical purposes, a foreign concept. Having a bad example is likely worse than having no example. If you cannot "think" in OO style, you're unlikely to produce good OO code. Similarly, if you know VB.Net very well and don't know PHP very much, you can probably produce excellent examples of solutions in ASPX/VB.Net, and very poor examples in PHP. If you still want to reproduce your system using OO, or functional, programming, find a colleague who is proficient in the paradigm of choice to implement it for you.


Teaching binary to 6-8 year olds I'm teaching some introduction lessons to a classroom of 6-8 year olds about basic 21st century skills. A fundamental part of this is how computers represent numbers, words and images, which all starts with understanding binary representation of a number.
When explaining this in the past, I have never not confused anyone with notation. For example trying to explain the difference between '11' (binary) and '11' (decimal) is hopelessly confusing because it looks like the exact same thing, and saying 'one one' almost always leads someone to think 'well one plus one is two, what is this dude going on about it being 3'.
I think the problem is that we use the same symbol for decimal and binary notation here, while there is not strictly a reason for it (it's convenient if you already know how it all works, but not before that).
So I'm thinking of using different symbols. Like ● for 'this bit is on', and ⊗ for 'this bit is off', so that I would write e.g.
3 = ●●

and
5 = ●⊗●

Any ideas on this? Would this help? Are there already other symbols being used for this purpose, symbols that don't rely on the glyphs we use for 0-9?

Use money.  Tell your students to image a country has bills that are in denominations of powers of 2:  1, 2, 4, 8, 16....  Now tell them this:  For a given number, count out that money with as few bills as possible.  You use a "greedy algorithm:"

Use the largest bill possible.
Repeat this until you have counted out the amount.

Questions to ask:

Did you ever use more than one bill from any denomination?

They should observe this is never necessary.

Now write a 1 for the largest bill.  If the next denomination down is not present, put a 0; otherwise, put a 1.  Repeat until you descend through the denominations.  You have the binary expansion of the integer you specified.

This is concrete and very easy for students to grasp.  This "greedy algorithm" works for any base: Use the largest bill you can can count out as many as you can at each stage.


What does a person with an undergraduate degree in CS still need to learn to be employable as a developer? Some recent CS graduates feel unprepared to enter the job market. Some may actually be unprepared.

What is missing from a typical undergraduate program, or not sufficiently emphasized, that a person needs to know for successful employment in a software development position? The gaps may be technical or not. What evidence do you have for the gaps you suggest? How can a person fill the gaps?
What advice can you give to a recent graduate about what they should learn on their own and how they might go about learning it? Advice might be for developing hard skills or soft and both may be needed to be employable.

Many entry level positions are not very challenging or rewarding, unfortunately. This may be the fault of the educational process itself, leaving graduates unprepared for better positions.

I assume that no educational program can teach everything. Therefore some things are emphasized more than others and some necessary things may be omitted, especially in a changing world. I'm not making an indictment of the educational process, but wondering what important things the individual still needs to know, and what skills they need, beyond their formal education.

My personal context is the US, but the same is likely true, but with different details, elsewhere. Your answer may depend on your own context, of course, so you may want to mention it.

To know that you know nothing.
Recent graduates can be afflicted by arrogance or low self worth. These are two sides of the same problem.
It is important to know that you are at the beginning of a journey, that has no end. The sum of all knowledge that is known, is but a drop in an ocean, and your personal knowledge is but an atom.
However this has not stopped other such as Turing, Lovelace, Hopper, Ritchie, Liskov, Stallman, et al; It has not stopped you in the past; and it will not stop you in the future.
Experience
I have heard many a new journeyman say “To get a job I need experience, but how do I get experience without a job?”.
So get experience: Find a good Free Software / Open Source project, that you are interested in, and contribute to the project.
Software engineering tools
As well as testing (@BenI). Revision control: Learn how to use revision control tools, for example: mercurial (hg), git, subversion (svn).
Of these subversion is previous generation, but still has some use-cases that best suit it. It is still widely used.
Mercurial and git are more modern, distributed systems. git is the most popular, but is a git to use, and very hard to learn. Mercurial is similar in how it works, but much easier to use (it has a more intuitive command line interface, and a nice graphical interface(tortoise hg)).


How can I improve my understanding in Computer Science? I am new to Computer Sciences, working as machine learning engineer. I only know the basics of programming.

How can I improve my technical comprehension so that I will be able solve different problems in Computer domain?

Currently I have difficulty understanding technical blogs. The terms and jargon confuse me. Even after searching for those jargon in Google, I feel I don't reach anywhere.

For instance I was given a problem of image processing yesterday by the seniors in my company. I had no idea how to go about it. When I read about it words like 'parsing', structure comprehension were thrown at me. I would like to know whether it is the lack of computer background that's the problem or comprehension or something else. How am I to deal it?

Abstract definitions are a deep rabbit hole. To illustrate the point:

First attempt

Imagine a non-English speaker trying to read the dictionary. First word: Aardvark. A nocturnal badger-sized burrowing mammal of Africa, ...
Wait, what does nocturnal mean? Done, occurring, or active at night.
Wait, what does occurring mean? ...

And this is the core of the issue: you end up with an ever-growing web of definitions composed of words whose definitions you don't understand. You've already had to look up more than three words and you're still not quire sure what an aardvark (the first word) is!

Second attempt

Let's try again. You're learning English because you want to work as a chef cook in an English speaking zone. You're going to be a pasta chef, so how about you look up the translation of dishes you know how to make. Afterwards, look up the translation of the ingredients you use to make these dishes.

Why was the second attempt so much more succesful? Simply put, because you were looking up the words that belong to a concrete concept you already know and understand.

  When I read about it words like 'parsing'

When you look up what parsing is, you will get some vague and generalized definition. The dictionary isn't much help here, even when looking at the computing definition. Google tells me:

  [COMPUTING] analyse (a string or text) into logical syntactic components.

This definition won't help you if you've never done any parsing before, or you haven't even thought about doing the act of parsing (even if you didn't know that it's called parsing).

So let's approach this from the other way: You are writing an application, and the users expect to be able to upload an excel file so that the data from the file can be saved in your application('s database).
How do you do that? Well, you will have to open up the file, look at the content of the file, and then add this data to your database.

Now you know that, it will make more sense what parsing is: parsing is making sense of the content you receive.
This can take on many forms, not just the reading of excel files. For example, when you ask Siri (or Alexa, or the Google Assistant) a question, it parses your sentence in order to understand what it means. When your web browser receives HTML from the web server, it parses the HTML in order to figure out what it needs to show to the user. When you load a savegame in a videogame, the game parses the save file to know what your last saved game state was.

So how do you learn computer science concepts?

The general rule is to approach it from a practical side. First, you try to accomplish something. When you struggle accomplishing it, or you want to read up on doing it even better; you will be able to look at the documentation and will already understand its inherent goal or what it adds.

For example, I am horrible at trying to understand new frameworks by reading the documentation or even seeing it presented. I learn much quicker by trying to use this, obviously failing because I don't know how to do things, and then look up how to do [simple thing, e.g. make the text bigger] in this framework.

By using this practical approach, my search for information is a directed search (like the chef looking for the translation of a dish he knows), as opposed to an abstract search (learning random words in the hopes that you'll want to use them in the future).

I'm not saying abstract searches can't be interesting. We've all spent some times clickbrowsing through Wikipedia or TV Tropes to find interesting things. But the abstract nature of computer science makes it hard to innately understand something you didn't know about before.

The best science teachers I've had always employed a similar strategy. At the beginning of the class, they pose a seemingly simple question, but the students are unable to actually find the answer. And only when they're curious about the answer to this question, the teacher starts to explain how to find the answer.

Other resources

The above answer is written in regards to your desire to self-learn. Of course, there are better ways of learning CS through courses and lectures. These courses are specifically designed to introduce concepts to you in a way that you understand them.
When self-learning, it's hard to know where to start and to separate the simple topics from the complex ones.

This is part of your issue. E.g. "parsing" is by no means a beginner topic. But if you had already learned the basics of file manipulation, collection (and preferably some OOP), the concept of parsing would've been a lot easier to understand from the get to. This is where guided courses help to, they ensure that you learn the necessary basics before starting on the more complex topics.

As an aside

  I was given a problem of image processing yesterday by the seniors in my company

I don't mean to offend, but if you're currently struggling to grasp what parsing it, you're way out of your league of broaching the topic of image processing. There seems to be a huge disconnect between your current skill level and the tasks you're being given.

Whether you're in over your head at your current job, or your seniors are oblivious to your technical skill level, in either case I suggest being open about what you do and do not yet grasp. Trying to tackle complex subjects without the necessary basic skills is not only going to take a lot of time and effort, but it will inevitably teach you some bad habits because you will be unaware of alternative options.


Teaching intermediate Java to students familiar with C The class I teach (a class whose teacher I assist1, to be precise) is learning intermediate Java this year (data structures, basic OOP and a few lessons about how Java actually works).

A few of the students have some familiarity with C and it would seem as though this makes some points or subjects difficult for them to understand (such as preprocessor, explicit pointers etc.).

This raises the issue of helping these students overcome the differences between a C mindset and a Java one. It was proven time and again that simply saying "That's just how Java works" is not enough (and frankly not very helpful).

So I'm looking for explanations (or analogies or examples) that might help students see the differences between the two mindsets in a clearer way.

Which points must be present in such an analogy, to properly show the main differences between the two?

1 I'm a teacher assistant in a high school.

I don't actually think it is necessary to show the differences (or the similarities). Treat Java as a new thing rather than trying to connect the new thing to the old (for these students only). Instead teach Java as a stand alone complete language. My preference would be to teach it from a high level rather than a low level, stressing abstractions via classes and (for you) the interfaces defining the data structures.

There is no reason in a Java course to discuss pointers or the preprocessor. Objects are "referred to" by reference variables, not "pointed to" by pointers. Learn and use the Java vocabulary for things. Once sends a message to an object, not "calls" a method.

In this way, your C students have a leg up on syntax, and the places where the "look of the language" helps them without getting into, likely only partially correct, analogies that may confuse them.

Work on the big ideas, encapsulation, abstraction, information management (hiding), polymorphism, etc, not the (possible, but likely not completely correct) explanation of the implementation. Treat a variable as a reference, not a "box". An object is a thing. The thing responds to messages, just like people do. Use Java analogies, not C based or assembly based analogies. There is no need of the higher to lower mapping. It will confuse some of your students. It buys you nothing. It may be the way you learned, but it is not optimal.

The purpose of a compiler for a high level language is to make it unnecessary to consider the mapping to the machine. Too many people forget that and try to teach as if that mapping is essential to understand to use the language. For them, computing is always and only about moving bits. They have learned nothing since 1955. Learn the language, learn the abstractions. Fly, don't crawl.


Gifted Student Presentations In working with a gifted student, I would like to set up an opportunity for him to learn some material and present it to the class.  How could such an activity be structured so that the presentation would be successful for him and for the rest of the class without becoming an unreasonable time-sink for the teacher?

For context, this is in a US-based high school, and the course is in theoretical computer science (the class is given the year after AP Computer Science A).

I did what the OP is describing for all of my students during the month following the AP CS exam in the U.S. Students were given a list of potential topics to research and then present. I also gave students some things the presentation needed to include:

At least two original examples (in code)
Well formatted and commented code
References useful for learning more about this topic
Some context to explain how or why this topic is useful

Students shared their presentation with me before delivering it to the class and I didn't need to spend much time outside of class working on this.

Since students had spent a year with Java, but actually covered very little of the language and standard libraries, some of the topics given involved delving deeper:

Using Threads and Runnable to handle concurrency
The Servlet API: creating a basic web application
Pick another language on the JVM and learn enough to demonstrate it
Lower level network code in Java: UDP for a chat app
Lower level network code in Java: Sockets
Parsing XML
Parsing HTML from a web page (e.g. stripping out the barometric pressure from a weather.com)


Opportunities for Interdepartmental Collaboration At my current school site (high-school level, 14-18 year olds), I am the only full-time CS teacher. While I don't mind working on my own, there are occasions where I think that collaborating on lessons (or a small part of one lesson) with colleagues would be beneficial. One opportunity I'd like to explore further is interdepartmental collaboration.

As of yet, I'm not entirely sure of how this would look. I do think it would be possible to co-teach a lesson with a colleague from another department. Alternatively, it would be feasible to take the "guest speaker" approach and either visit a colleague's class or have a colleague visit mine. This at least creates content connections between curricula where relevant.

Are there concepts at the introductory or AP levels of high school computer science that are appropriate for or lend themselves to this kind of collaboration? What other disciplines are good fits for collaboration with CS, and where does CS expertise fit within them?

Some ideas to ruminate on.

With you as the guest in another department, thoughts are:

$\LaTeX$ presented to a writing class, preferably one where they've already had to submit three or more papers that were graded on presentation as well as English usage
Web design (for portfolio usage maybe) to any arts or photography class
Mathematica, if available, to any advanced mathematics or lab sciences class
SQL (any flavor) to any business-related classes, if any exist at your school

At these engagements you can show how the program can be used in real-world application to what they are learning, and/or be useful to them in their class now. Best of breed for that would be the use of $\LaTeX$ for the writing class - freeing them from formatting and presentation details to work on their writing skills

As a guest in the computer class, you could look for any instructors that rely on computer programs in their course material. Especially useful would be any that employ a program that is Free/OpenSource software. (If it is hosted on GitHub where they can also look at, that's even better.) A good candidate might be an art class that uses GIMP.

If you find a significant portion of your students have a common interest in another field, you could engage that department for a collaborator who can show how the computer is used in their field, even if it's not applied in the classroom itself. (Of course that could also include teaching those instructors as well, so that they are in a position to understand the tools at least as well and the students they teach.)

Lastly, to get things rolling, you could offer to do a session or two in another class to teach their students extra features of the Office software that they use, if any, with the students. Lab science classes probably need at least Excel for processing and presenting measurement data from experiments.

The first set of ideas is to present how the use of computers can help them now with their classwork. The second set is to show your students the application of what they are learning in your class to things they already know, or will be taking soon. The third set of ideas shows how computers are being used in the work-a-day world to make things easier, or better, in the field they are really interested in. The final idea is a method of beginning the idea of collaboration in your school before the other instructors realize it's even possible.


Using questions from a code-competition website in homework and exams There are various websites like codewars that present programming challenges in various languages and difficulty levels.
I looked at some of their challenges and they seem to be more creative than me in making good questions. So, I thought of using this website as a source for exam questions in a programming course I am going to teach next semester.

My plan is to tell the students in advance that some (or all) of the exam questions will come from this website, so that they have the entire semester for practicing. Moreover, I plan to tell them that, if they have any difficulty in solving a challenge, or want any feedback on their solution, they can ask me or the other course staff for help during the semester. My hope is that this will encourage them to practice programming in a competitive and fun environment. Do you think this a good plan? Do you have experience using such websites in programming courses?

Whether this is a good plan or not depends on some things, most especially the nature of your students.

However, it seems a bit too unstructured. If you have a general mix of student ability it could cause problems unless you incorporate the questions from the site(s) more formally into your teaching. There are a lot of questions available, I would guess and some of your students will panic, thinking that (a) they need to do everything or (b) it is hopeless. This is a special problem if these extra questions are above and beyond all necessary assigned work.

However, one good aspect of your plan is to show them in advance the kinds of things that they will be expected to know and that other students also regularly deal with. Much better that than hiding your intent and springing things on them unexpectedly.

But I think a better plan is for you to incorporate a sampling of the found questions into your labs and homework assignments. For the most challenging questions you could have five minute brainstorming sessions as part of several class periods.

In short, as part of the regular process it should work out, but if it is completely "extra but not formally rewarded" work it might backfire on you.

An additional dimension here, of course, is that you could use the site(s) to teach yourself how to ask better questions. And your focus on "creative questions" rather than necessarily "challenging questions" is a good one, I think.


Analogy for teaching recursion When teaching recursion, what is the best analogy people use to teach the idea of recursion. There are some nice artistic representations

And the idea of repeatedly cutting a phone book or dictionary in half until you find a number/word (basically binary search). The only problem is students don't use phone books/paper dictionaries anymore and the artistic representation doesn't imply an end goal/state.

The Tower of Hanoi was one of the first ways that I encountered recursion.

"The objective of the puzzle is to move the entire stack to another rod, obeying the following simple rules:

Only one disk can be moved at a time.
Each move consists of taking the upper disk from one of the stacks and placing it on top of another stack i.e. a disk can only be moved if it is the uppermost disk on a stack.
No disk may be placed on top of a smaller disk." (from Wikipedia)

To solve the n disk tower problem:

Solve the n-1 disk tower problem
Move the nth disk
Solve the n-1 disk tower problem again.

Solving the 1 disk problem is trivial.

I can imagine coding this as a nice on-screen or physical computing challenge.


Answering student questions as they work outside class If your students are like mine, they do a lot of their work outside my view; at home, on weekends, etc. But as they work they sometimes get stuck. They get questions for which they need the answers in order to continue. Sometimes it is a long time before the next class period or office hour.

Suppose that you would like to be able to answer their questions as they arise, but without disadvantaging other students who may have the same question but didn't think to ask. Sometimes, in fact, a student finds an inconsistency in something you said or gave them, and needs a correction before they can continue.

What tools and mechanisms do you find useful for letting students get necessary answers, at times you are not in class or office hours? I'm looking for actual solutions, not guesses about what might work or which make someone's life (mine) miserable. I'm pretty sure that giving out my cell phone number fails on too many levels to consider.

Threaded discussion forums allow everyone to see all questions and answers and to post questions and receive answers at any time that you find convenient to check in and update. I have used this in online teaching before. It works very well.

Actually, I don't know of anything else that does or would work. I would love to hear about other possibilities.


relationship between ACM curriculum guidelines from 2013 and computing curricula 2020 I have been working with the ACM Curriculum Guidelines for proposing courses and topics related to CS in the Faculty that I am currently working on. The core document that we have been using was the ACM Computing Curricular Guidelines from 2013. At the beginning of this year, it emerged the ACM Computing Curricula 2020, which I believe is an improvement over the original document from ACM circa 2005, which defined the guidelines of CS-related careers. The document can be found on:
https://cc2020.nsparc.msstate.edu/
Here I have some doubts about this initial draft. I have seen that (in my personal opinion) it is a little bit awkward. It mentions the different "flavors" of CS worldwide, and then it shows some tools that could be used to measure to see how much CS one career has, even though it does not mention where and how to use these tools. The nice thing about this document is that it contains a set of competencies that should be attained from each undergraduate CS-related field, which, by the way, vaguely reminds me of the ABET competencies system. However, I miss the style of the Curriculum Guidelines of 2013; in which there were recommendations on how to distribute the Body of Knowledge into different Knowledge Areas. Also, even it gave a summary of the recommended topics in each Tier (core or elective).
In summary, I would like to know if one should use this document of 2020 in conjunction with the document that appeared in 2013. Maybe is that ACM will develop another document as an upgrade to the 2013 curriculum guidelines? Any comments or suggestions on how to use this new ACM CS 2020 guidelines?
Thanks

Actually, since it is a draft report, you have an opportunity to influence the final version. Contact one or both of the Co-chairs. They can also give you some more information on their thinking. I'm not personally involved in this, but know several of the participants. They are likely to be helpful.


How can I effectively manage peer evaluation among my students? My students do quite a lot of their work in projects and much of that work is outside my view. While I can just give everyone on a team the same grade (or not) it is useful to me to know who is contributing to the work and how they are contributing. I don't require everyone contribute either the same "amount" (whatever that means) or in the same way?

How can I manage peer evaluation so that I get useful information for grading, for advisement, and for course improvement?

I want my students to have a way to comment on the work of their peers on group projects. They can also comment on their own contributions, perhaps, as well. This is especially valuable, I think, when students do much of their work outside my direct view.

I need the peer evaluation to not seem threatening to the students, and I don't  want it to generate ill feeling among them.

To make the problem a bit harder, I don't want to divide up the work among the team members myself as I think that would inhibit their learning to be a team. The team itself is responsible for managing its work. Ideally, however, I hold each responsible for the team effort.

Something like the following has worked for me over several years. In any group assignment, each member of the group also submits a peer review sheet. For a group of two (e.g. pair programming) I ask each participant to detail the most important contribution of their partner AND their own most important contribution. I don't ask who worked harder or ask them to make an evaluation. I ask them for the contributions.

In a group of about five, I will ask each member to name the (say) three most important members of their group and to mention the key contribution of each. I tell them that they can include themself in the list of three. I also ask, separately for their own most important contribution.

I let them know at the beginning of the course that this will happen and its parameters, so it isn't a surprise.

Students see that they are supposed to contribute to a group and are not asked to speak ill of anyone. Keep the questions entirely positive. But you also learn a lot from what is not said and who is not included in the contributor list.

If the project happens outside your view, you also learn things about individuals that you can not otherwise know. I've had students I thought were slacking who were praised by teammates for making the team work properly.

These peer evaluations are not optional.

This same idea was also discussed here: https://cseducators.stackexchange.com/a/2578/1293
It is also, essentially identical to part of this: https://cseducators.stackexchange.com/a/3402/1293

Let me note that there may be cultural limitations here. In some cultures it may be odd to name oneself as a top contributor. In others it might be very natural. You can modify the scheme, of course, either requiring or forbidding naming oneself as one of the top people. Use your judgement here.

Note also that this solution is based on the Peer Feedback pattern in Pedagogical Patterns: Advice for Educators


How can I incorporate agile development into CS1/CS2 courses? I would like my students to get the most out of the course by experiencing an agile development structure in their projects. Currently I give 5 assignments, each building on the previous one and adding to the complexity of the final product. Although this is far from letting students experience "real" agile development, it is a first step. How can I incorporate an agile development methodology backbone to the course, letting students experience it first-hand? The courses are taught in Python (CS1) and Java (CS2) and this is an Applied Information Technology program.

Don't.

Agile is great, but it's mostly about how to manage the development process, interact between the different parties involved, communicate status and break down larger projects of work into achievable segments. When you're trying to understand what a loop/function/class/object/etc is there's really no need to also think about the software engineering issues for larger projects, teams, etc. Students only have capacity to learn so much and I'd argue it's counterproductive to have them spend some of their attention on learning agile.

By all means talk about it if you're looking at software engineering practices, but it shouldn't be a focus.

Test driven development might be ok to teach, although I suspect it will just complicate things for new students.


How to supplement Khan Academy First: I'm a coder, not a teacher.

That said, I led a 4-session "Coding for Teens" class at a local library this month using Khan Academy (KA). I'm contemplating scheduling another series maybe in August but I'm struggling with why they would actually need me for this.

The KA curriculum is pretty complete and self-contained. I was able to add value by filling in some facts about how variables work that KA didn't get into. But beyond that I'm wondering why I'm even there.

I would try doing some class-participation exercises at the board but KA is self-paced & the students are at very different places.

At the end of the 4th session I had them do a class evaluation & they all (full-disclosure: only 3 of my 6 showed up to the final session) gave the class high marks in general and expressed interest in another series, but if I do this I'd like to feel like I add more value than a mannequin would.

In case it helps, my "teens" are a mixed group of girls and boys from middle-school to dual high school/college enrollment. And I have one "teen" whom I suspect no longer actually qualifies, but it seems rude to ask & I don't really care.

Note, IMO this question is distinct from that one because that question is about supplementing a curriculum with KA (or others) whereas I'm asking how to supplement KA.

I think you might be underselling your sessions a bit -- understanding how to effectively independently learn is a non-trivial skill that not everybody has mastered, and just being available to facilitate things and answer questions can be very valuable to your students. Having regular sessions that impose some structure and providing a small community of peers who share similar interests can also be helpful.

In any case, one idea is that you could perhaps try and help guide your students towards working on their own, independent projects. I've found that students (especially ones who are self-teaching) often have difficulty applying what they've learned to build programs on their own -- it seems making the jump from working on guided exercises to fully independent projects is non-trivial for many people.

What you could do is try and make sure your students all make it over that "jump" in some fashion. One idea for doing this might be to slowly start weening students off Khan Academy and have them work on a mini-project.

In particular, here are some of the things I've found seem to make that "jump" hard for beginners (and so are things you can help with):

Idea formation: beginners often find it difficult to imagine what's even possible with code (if statements and loops feel very far removed from websites, mobile apps, games, etc to a novice), and to understand how to connect their existing interests to code. (If a student is interested in games, sure, that's an obvious connection, but seeing how to write code to do things related to music, English, politics, knitting, sports, etc can be non-obvious.)

What you can do here is provide example project ideas, help students brainstorm, and perhaps do some preliminary research yourself so you can point students in interesting directions.
Project planning and problem decomposition: your students will likely need help scoping out a project and creating a realistic timeline appropriate to their level of progress and the amount of time they have. You can help them identify how to break up their idea into smaller, more manageable sub-goals, suggest some initial tasks, help them outline their overall program structure, etc...
Setup: most projects will need students to install libraries and setup their dev environment in more sophisticated ways then most tutorials cover. They will definitely need your help here -- setup can be incredibly frustrating, even for experienced devs!
Independent learning: Learning how to work through tutorials, read documentation, and compose effective google queries are all skills that more or less need to be trained. This usually happens implicitly through experience, but just being available to answer questions, give impromptu mini-lectures on related topics, etc can make things go much more smoothly for the students.
Debugging: Same sort of thing; debugging is hard, you can teach them strategies, help prevent them from being frustrated...

That said, you'll have to plan this carefully to avoid overloading your students. It's very likely that many of them practice coding only during your sessions and weren't planning on coding in their spare time (since it's the summer, after all!). Ideally, you should try and motivate them to work outside your sessions, but you should prepare contingency plans if that doesn't end up happening. Trying to complete even a small project in only 4 to 5 sessions will likely be a bit of a stretch, depending on how long your sessions are.

You can perhaps partially solve this by talking to your current students about these concerns to try and get buy-in if you're planning on having your next sessions be a continuation, or to directly state your expectations when advertising your sessions or something.


Note-taking policy: laptops, or by hand? My students are all highly inclined to take notes on their computers.  There are some obvious advantages:

The students absolutely prefer it.
They can easily search through their notes later.
Since their computers are out, we can easily do code-alongs or other short coding exercises.

However, I also read that taking notes on a computer leads to poor retention and comprehension.  I have been considering banning computerized notes, and requiring either handwritten note taking or telling students to forego notetaking altogether, and simply giving them my powerpoints after the lecture is over.

What are the advantages and disadvantages of such a classroom policy.  Which is better?

Neither is better. What is true for one student may not be for another.

Studies can show trends. Students are not trends; they are individuals.

As an example I encountered today that seems to go against that wisdom, I caught a news piece about a local girl in the Scripps National Spelling Bee. As she spelled the word she was moving her fingers in a weird fashion. Half-way through the word I recognized what she was doing. She was "typing" the word as she spelled it. She was able to remember how to spell the word by remembering how she would type it.

I have personally attended classes with someone who "doodled" their notes. She drew random-looking doodles, not pictures or pictographs, as the instructor presented. Later she was able to translate her doodles better than I could translate my long-hand notes. She also scored better on the fact-based questions than most of the class.

There is one major drawback to laptop note taking in class, however: noise. Few keyboards are truly silent, and the key noise, even if it's just the sound of fingernails hitting the plastic, can be very distracting to other students.

If you're willing to allow it, and school policy does not prohibit it, a third option is audio recording.

I've only been in one classroom where computers were allowed to be on, and it was distracting. I've never allowed them to be used when I lecture, or even during study time unless it's also lab time.

What seems to work best for situations involving lots of data, especially where layout and syntax can be significant, is to provide the lecture material in some manner after the lecture has been delivered. That could be done via Google Drive, or some other online source. Online access allows the student to retrieve it when they need it without having to access it immediately after the lecture. It also helps for the disadvantaged students that may not have laptops to bring to school. They can access it from the library, or any other source of online access.


Some real practical example to teach object-oriented concepts and programming (in python) I have taught my high school students to write some simple python scripts, taking some ideas from "Automate the Boring Stuff with Python", e.g. changing file names in a folder to a specific naming pattern.
My next goal is to teach them object-oriented concepts and if possible give them some "real" examples to try themselves. But most of the materials I find (most of google's top search results) about OO programming (not just python) are laden with poor examples, if I may say so. I really don't like to use car/vehicle or animal/dog to teach them the OO concept and OOP.
A. it is boring (you know high-school kids)
B. it has no real use.
C. as one comment said "they are fatally flawed."  (But if you really like to use the animal example, check this "Object-Oriented Design")
I plan to use pathlib (btw, they already have a basic idea of the difference between Windows and UNIX)

GUI development could be another good example to teach OOP but I don't want to teach them GUI yet.
Any suggestion to introduce OO with the "real" example?
BTW, I’m not a strong advocate of object-oriented programming. But the pathlib.Path class is a useful abstraction especially compared with os.path, although the high school students are unlikely to appreciate that.
---- update ----
I find the python logging module is another good example, but it seems too complicated for non-experienced programmers.
When using the logging module we mainly use 3 objects, Logger, Handler, Formatter. Logger is the facade, as https://docs.python.org/3/howto/logging.html#loggers said,

Logger objects have a threefold job. First, they expose several methods to application code so that applications can log messages at runtime. Second, logger objects determine which log messages to act upon based upon severity (the default filtering facility) or filter objects. Third, logger objects pass along relevant log messages to all interested log handlers.

Handler is a good example to use inheritance https://docs.python.org/3/howto/logging.html#useful-handlers and handlers use formatters, which hide the complexity of LogRecord, to the format log message.
In addition to these classes, there are a number of module-level functions for convenient use.
Overall it is a good example of using composition and aggregation.
But I am not an expert on the python logging module, I hope someone who is familiar with the python logging module may add an answer to my question.
--- update 2 ----
I found Alan Kay answered the question “What are the five features of the object-oriented paradigm that you consider to be important for good software engineering practice?” with these words, in my opinion, resonate with the answer Buffy gave. But how to convey these ideas to high school students or non-experienced programmers is another challenge,

a “part” construct that can protect it's inside from its outside, and
vice versa
a “communications” construct that can convey interactions and deal
with dependencies
a “system” construct that is a combination of parts and communications
that can fit in a part recursively, and everything is made this way
the “messages” that are communicated are also in terms of the systems
the system that is being made is made with the same kinds of system
...

I expect to update this a few times and hope to eventually have a long answer.
But let me start by explaining some things that you may already be aware of, but other readers may not.
First, OO programming is not, fundamentally, about inheritance and too many books and authors fail to understand that. Moreover, they use inheritance in a dreadful way that makes software hard to understand and harder to maintain.
For example, note that the Linnaeus style hierarchy of the biological world is almost entirely one of "interfaces" and not even "abstract classes", much less concrete classes. There are no instantiated "mammals", for example. It is only at the leave of the hierarchy that things actually exist, other than as ideas. There is some genetic continuity, of course.
Second, there are some principles that can guide you in writing and teaching OO design, but they require discipline. And part of that discipline is to control the situations in which you "break" the rules.
My first advice for anyone wanting to be an OO programmer is not to think in terms of inheritance, but, rather, of composition. Complex things (objects) are composed of other things (objects) that are a bit simpler than the containing object and provide it some essential service. If you write classes where all (or even most) of your instance variables are language primitives, then you don't really get it. And if those instance variables (objects or primitive) have a lot of getters and setters, then you aren't doing OO Programming at all.
In fact, making the above mistakes, requires that the programmer keep track of all details at all points of the program where OO is designed to capture decisions so that they needn't be "checked" again. Set it and forget it, so to speak.
So, if you want to build an automobile, don't think of it as a subclass of vehicle (which gains you nothing: a personal drone and a battleship are both vehicles). Think of it instead of being composed of various parts: engine, transmission, controls, accommodations, etc. And those parts are, themselves, composed of parts. An engine has igniters and pistons, exhaust, etc. Many of those are composed of parts also. It is only at the lowest, simplest level that you build with primitives.
Two of the principles that are worth keeping in mind and following almost always are the Liskov Substitution Principle and the Law of Demeter.
The first suggests that if you extend a class with a subclass you don't also extend the public interface of the subclass. Then all subclass objects are substitutable, differing in behavior but not in interface. Demeter, on the other hand, forces you to write more explicit code that makes relationships clear to a reader. Of course it also forces you to introduce more name, and if they are intention revealing names then your code is clearer.
The Liskov principle, of course is one of the elements of SOLID which you also need to incorporate into your thinking.
In my own programming I'm very faithful to Liskov, also defining Interfaces for most things before I write classes. I'm less faithful to Demeter in the heat of battle, cascading messages. But then I sometimes also need to unravel those a.b.c.d sorts of cascades to figure out what I really mean.
One goal I have in writing OO code is to seek to write only very short methods with a minimum of structure. In other words I try to minimize Cyclomatic Complexity. My palms start to get itchy after the fourth statement in a method of if the complexity level reaches three. I can't always get away with that, but it is a goal. The solution is to refactor complexity mercilessly. Factor out methods, of course, but also "parts", creating new classes to manage the complexity. Even if many of those classes are Singletons the code is usually improved and having the goal in mind from the start, means that the refactoring step is less needed.
Design patters are tools that you need to be an effective programmer in most OO languages. Especially helpful ones are Strategy, Decorator, Observer, and Iterator. Most of these are actually used to build the various Java libraries.

Now, to get to the actual question asked here. But note that a lot of learning can take place even if the students never reach completion of the project in the allotted time. An agile approach (Extreme Programming, say, with you as "Customer") to development leaves them with some functionality even if not all specifications are implemented.
Dungeon Game
Build a text based dungeon game. The main objects are characters (people), places, and things. The places are organized in some sort of map, maze, or grid. Things happen when characters enter places. Characters find and carry things. The things have actions, depending on the kind of thing. A "spell" is a "thing" whose action might depend on context. A "transporter" object might work differently in different rooms (strategy objects).
Note that the classic board game Chutes (or Snakes) and Ladders is a simplified version of this. A text based version avoids a lot of complexity.
Calculator
A calculator has parts such as keys and the display. Less visible are the internal memory, possibly a stack. Even the operations can be objects. The behavior of the keys changes, depending on the state of the computation (Strategy pattern). It is possible to build a simple calculator without a single IF statement, actually.
Abstract Computer with an Assembly language
A Stack Based computer processor simulation is pretty straightforward. There may be accumulators and such, but a single stack on which all operations are done is simple and complete. The operations can be objects (parts). One advantage of this example is that most of the necessary methods can be very short. A program can be read with a Java Scanner object. It needs a program counter at least and possibly a frame pointer if the language is to support subroutines.
Sticky Notes (I haven't tried this)
An application that lets users keep notes and cross reference and organize them. Some classes might be Notes, Keywords, Connections, Lists.
Jeopardy
A simulator for the jeopardy game from TV. Categories, Answers, Questions, Teams, Scores.
(Back soon, maybe).


What are "general purpose programming skills"? The UK introduced its National Computing Curriculum a couple of years ago, which requires all children to study computer science from age 4, and programming from age 10. Children can opt out of the subject aged 16.
Schools are struggling to implement the curriculum, mainly due to a lack of teaching staff that can program, but the hope is that things will improve over time.
The UK National Curriculum defines three key skills (English, Mathematics and Science) that must be studied. Computing is defined as one of the four sciences (along with Physics, Chemistry and Biology), which is why British children must now learn to code.
Some people argue that traditional computer literacy is a specialist skill, and do not think the subject should be mandatory. The counter is that the curriculum is not designed to teach specialist skills, insisting that there is a core subset of programming concepts that every educated person should understand.
The official guidance does not make it clear which programming concepts should be taught, instead offering vague recommendations. This is about as good as it gets:

use 2 or more programming languages, at least one of which is textual, to solve a variety of computational problems; make appropriate use of data structures [for example, lists, tables or arrays]; design and develop modular programs that use procedures or functions

understand simple Boolean logic [for example, AND, OR and NOT] and some of its uses in circuits and programming; understand how numbers can be represented in binary, and be able to carry out simple operations on binary numbers [for example, binary addition, and conversion between binary and decimal]

I understand this is not the place for a debate or discussion, so would like to ask if anyone could define what general purpose programming skills are, with any clarity?

General Purpose Programming Skills
General purpose programming skills can also be called Computational Thinking. Computational thinking has four cornerstones¹:

Decomposition - breaking down a complex problem or system into smaller, more manageable parts
Pattern recognition (data representation) – looking for similarities among and within problems
Generalization (abstraction) – focusing on the important information only, ignoring irrelevant detail
Algorithms - developing a step-by-step solution to the problem, or the rules to follow to solve the problem

Computational Thinking: What It Is, and Isn't
Jeannette Wing, formerly head of the Computer Science at Carnegie Mellon Univ., Pittsburgh, PA, USA published an article in Communications of the ACM where she covers, rather nicely, the ideas of computational thinking, and how it differs from computer programming.²

Conceptualizing, not programming. Computer science is not computer programming. Thinking like a computer scientist means more than being able to program a computer. It requires thinking at multiple levels of abstraction;
Fundamental, not rote skill. A fundamental skill is something every human being must know to function in modern society. Rote means a mechanical routine. Ironically, not until computer science solves the AI Grand Challenge of making computers think like humans will thinking be rote;
A way that humans, not computers, think. Computational thinking is a way humans solve problems; it is not trying to get humans to think like computers. Computers are dull and boring; humans are clever and imaginative. We humans make computers exciting. Equipped with computing devices, we use our cleverness to tackle problems we would not dare take on before the age of computing and build systems with functionality limited only by our imaginations;
Complements and combines mathematical and engineering thinking. Computer science inherently draws on mathematical thinking, given that, like all sciences, its formal foundations rest on mathematics. Computer science inherently draws on engineering thinking, given that we build systems that interact with the real world. The constraints of the underlying computing device force computer scientists to think computationally, not just mathematically. Being free to build virtual worlds enables us to engineer systems beyond the physical world;
Ideas, not artifacts. It’s not just the software and hardware artifacts we produce that will be physically present everywhere and touch our lives all the time, it will be the computational concepts we use to approach and solve problems, manage our daily lives, and communicate and interact with other people; and
For everyone, everywhere. Computational thinking will be a reality when it is so integral to human endeavors it disappears as an explicit philosophy.

1: Source: BBC Bitesize - KS3 Computer Science - Introduction to computational thinking
2: Source: Jeannette M. Wing "Computational Thinking" Communications of the ACM. 49 (3): 33.


Does teaching an intro course with a functional language really help level the playing field? On another question, Ben. I claimed:

  By utilizing a functional language in your first course, you get to
  have a classroom full of kids who have a much more similar footing.
  And when you move on, later, to imperative programming, you no longer
  have any kids with no experience. It's a simple trick to keep your
  cohorts more on-level without wasting the time of the advanced
  students.

I've heard this argument before and wonder if it's really true. The first programming course I encountered was in Scheme, and it seemed that students with prior programming experience (even in imperative languages) tended to do well in the course, while some students without prior experience were lost. Of course, my undergraduate days were long ago, correlation does not equal causation, and my data is anecdotal.

Is there evidence that using a functional programming in an introductory college course reduces the effects of differences in programming background?

Let me mention, at least, another dimension to this. There are various functional languages and some of them are closer to what your students may have in their backgrounds. A language with dynamic scope and abstract syntax is a very different beast from one with lexical scope and a rich syntax.

The only functional language that I really worked at was ML and I got quite good at it. But I learned that I really want the concrete syntax that it offers as an aid in my thinking. The underlying concepts are the same, of course, but I'm pretty worthless in Scheme. But then, I didn't learn Emacs from my mother as many schemers seem to have done.

So, if you want to level the playing field then I will guess that you want something as unlike their previous experience as possible. Say Scheme, rather than Haskell.

However, some students will pick up the new ideas faster than others no matter what you do, so it is good, in my view, to take advantage of that.

And of course, if you are going to do something very non-standard, make sure that you have the necessary expertise first. That isn't a situation for staying one chapter ahead in the book as some instructors are forced by circumstances to do.


How do I deal with students being unkind to each other when I'm not there? The faculty and students at my small minority-serving institution think of our environment as being supportive and cooperative. This is very important in CS, since programming is a team sport, and students are expected to seek help from each other (and TAs and me).

I have heard recently from two unconnected students about other students ignoring or being rude to them (such as walking away mid-question). The complainants don't give names, and I have no idea who they're talking about.

Almost all of the students in our program belong to at least one demographic underrepresented in CS and/or in the US. The students who have been mistreated belong to multiple such demographics and think that may be a factor. I have no way of knowing if they're right. Each is the only student of their cohort in their demographic.

What can I do to encourage students to better treat classmates? Some have been at the institution much longer than others. The ones who feel mistreated are newer arrivals. While my top goal would be changing students' behavior, we all know it isn't always possible to get people to change. If I can't get people to change, how can I know who should deserve bad citizenship grades or to not get letters of recommendation? I am not interested in furthering the careers of people who mistreat others.

I have a couple thoughts of how I'd handle it:

Address it with the bad actors 1-on-1, but don't assume bad faith. We might not know the whole story and there might have been a good reason to walk away from a situation or it is possible that the bad actor has poor social skills. Give them the benefit of the doubt, but explain why that kind of behavior creates a hostile environment that is not good for education.
Discuss in class what makes for a good working/learning environment. Not necessarily directly mentioning the situation, you can still emphasize a need for students to take agency in being part of a nurturing environment. I haven't had the exact same circumstances, but I have found it helpful by acknowledging that most jobs require interpersonal skills and that I've known even talented developers who have been passed up for good jobs because no one wanted to put up with their attitudes. In that same notion, I tell my software engineering students that I expect them to behave like professionals and like the class is a part-time job. That includes treating others with respect, even if they don't consider each other friends.

If you find it is a continuing problem, you might consider working into your assessment plan some way (even as a small percentage of the overall grade) to evaluate individuals' professionalism in-and-out of the classroom.


How do I convince my students that visual programming is real programming? I have been considering taking a visual programming language, such as Snap!, to my high school students as a way to make some of the concepts we delve into a little more fun.  The kids themselves already have a pretty substantial background in Java, Python, C and 6502 assembly, and many of them are also familiar with the JS/PHP/SQL stack for web dev.

I have a very strong feeling that they won't consider a block-based language to be a real language, even though it contains typing, parameters, lambdas, etc. How do I get past the initial hump and persuade them that this is worth their time?

Two thoughts:

I'd start with telling them why you think it's worth their time.  Whatever I or anyone else says on here, you're the one who thought it would be fun and worthwhile, and you must have reasons for that.  Your reasons are more authentic and probably more applicable to your students than our reasons will be. Just be straight with the kids about what they are.
You mentioned assembly, C, Java, and Python, which means that the kids not only have experience with "real" languages, but they have experiences with languages with a wide range of abstraction.  You can present DnD/block programming languages as yet another level of abstraction, in which common language structures (blocks and certain bits of syntax) are abstracted visually rather than textually.  This is not so radically different from what Python does when it visually presents code blocks as indented regions rather than as text sandwiched between curly brackets.  You can point out the similarities between the block interpreter and the Python interpreter. You can compare the power, efficiency, learning curve, and programmer time requirements for each language and maybe even make a nice chart on the board.  This will reinforce the idea that when comparing Snap! to Python to C, they really are comparing apples to apples.


Books that summarize pedagogical research within our field I was inspired by BennetBrown's answer here, in which he says

  "Please, CS ed, produce something akin to Teaching Introductory Physics. Guzdial's Learner-centered Design of Computing Education is a wonderful book, but we have a long way to go to match the physics education community's understanding of their craft."

Which got me thinking that I really did want to expand my craft, and that a book would be just the thing.  In my searching, I of course found Guzdial's Learning-centered Design (which BennetBrown mentioned), but I also found  this: Guide to Teaching Computer Science: An Activity-Based Approach.

However, I can find precious little detail about either volume.  Are there significant differences between the two that I should take into account when selecting one of them?

EDIT:  I also just found Pedagogical Patterns, which does not claim to be a CS book, but its primary two authors are Computer Science professors so it might also fit into this question.

(Also, I believe that these are the only two books like this, though if I have missed one somewhere, leave a comment and I will integrate it into the question.)

Here are books in print that address a range of issues within teaching computer science, synthesize pedagogical questions and research-based answers distilled from research, and include extensive references to the literature.

Frieze and Quesenberry. (2017). Kicking butt in computer science: Women in computing at Carnegie Mellon University.
Summarizing the efforts at CMU to diversify CS undergraduate enrollment, the book is intended to help CS teachers duplicate CMU's success by focusing on benefits of diversity rather than gender differences.

Guzdial. (2016). Learner-centered design of computing education.
Intended as a review of literature on teaching CS to people who are not aiming to be CS professionals, the seven chapters define the problem, summarize the research, and ask many questions yet to be answered in the literature.

Hazzan, Lapidot, and Ragonis. (2014) Guide to teaching computer science, 2nd edition.
Intended as textbook for a CS teaching methods course, the Guide helps a CS Methods instructor model active learning techniques by structuring the text around 110 activities in which the CS teachers are the participants.

Kafai and Burke. (2014) Connected code: Why children need to learn programming.
Describing educational programs that have worked with children, and the programs' results, this book aims to help teachers and influencers lead cultural changes toward computational participation and new ways of thinking and learning.

Krauss and Prottsman. (2017). Computational thinking and coding for every student.
Aiming to help the K-12 teacher with no CS experience, this book offers lesson plans, resources, and pedagogical advice mirroring the consensus of the CS community. Self-described as a "getting-started guide," it is not a review of literature, the the References list about 50 sources, some of which are research articles.


LINQ to SQL alternative C# Visual Studio 2017 MVC I'm working as a teacher with college students, learning ASP.NET MVC with C#.

One pedagogical problem I have in this environment is how to do CRUD (create, delete, update, select and inner join etc) in the simplest way?

With ASP 6.0 the students had a big control when querying db with plain SQL. With Entity Framework, the learning curve is harder with the code used to get data from database etc.

After almost 20 years working with php/apache/mysql and asp/ms access there is hard to know which way to go, giving the students "basic/intermediate" knowledge in building dynamic responsive websites connecting to db.

A couple of years ago we started focus on c#.net and sql-server/LocalDB. A great decision! Two years ago we dived into ASP.NET MVC. Fun, but really hard to penetrate for the students. To be more exact, LINQ to SQL, MVC and entity framework are hard to handle in "this levels" and with shorter courses. Are there any good alternatives for LINQ to SQL working in Visual Studio 2017?

I cannot think of a better alternative for LINQ to SQL, especially in Visual Studio 2017. You have said that you have spent 2 years already into MVC, which means, familiarity with MVC can be assumed.

If so, I would say that don't give up on the LINQ + SQL + EF + MVC ( I will simply refer to this as the MVC combo ) combo yet. I am guessing that you have already looked at this link. I use that in my introductory sessions on MVC, and even newcomers ( I mean, people who have not even tried MVC, or any of the MVC combo components ) have found it easy to use. In my experience, 10 to 15 hours is all it takes to train folks on that (at least the basics).

Give it a go, and yes, if you have questions about that link as you teach the different sections, come back and post questions here. We will take care of it for you.


How to teach a flipped course based on the AI MOOC? I'd like to create a college-level AI course based on the famous AI MOOC created by Peter Norvig and Sebastian Thrun. My reasoning is that I wouldn't be able to create lectures as good as theirs, especially because I'm not particularly knowledgeable about AI. (The last AI course I took was in the early 90s.)

I would teach a "flipped" course in which the students watched lectures on their own, and we used class time to:

prepare them for upcoming material they might have trouble understanding (based on my knowledge of their background).
answer questions or elaborate on recently presented material.
supervise group work to apply what they've learned.

Beyond these general principles, I have no idea how to teach a flipped course. Can anyone offer guidance or resources, both in general or for this specific course?

I've hated the term flipped classroom since I first heard it. It was as if those young kid teachers invented a new way of teaching that us old folks could never have done.

We had flipped classrooms back in the day - it was called homework. When the history teacher said "watch the debate" - flipped classroom. Reach Act IV of the play? - flipped classroom. Reach Chapter 5 and try to do exercises 1-3? - flipped classroom.

So, you'll have similar issues with the MOOC but your homework are the videos and related content.

Some thoughts:

Will all the kids watch the videos? How will you handle it if a number don't or if they superficially watch it. There are embedded exercises but you can still "skim" the video and get through those. You'll want to have a plan if this happens.
The lectures are pretty good (I went through the MOOC when it first came out) but there are a number of holes and ambiguities. If you haven't already, go through all the videos with a teachers eye and you'll find a number of holes that the kids can fall through unless they think exactly the same way Norvig and Thrun are teaching.
This may have changed since I went through the MOOC but it was designed for individual participants working in isolation. Most of the exercises and the programming assignments thus are solo you'll want to work out group projects in advance to supplement what they're asking.
This also might have been addressed but there were a number of ambiguities in the lectures (depending on ones interpretation) which became clear after doing the online quizes (and depending on your interpretation, maybe getting them wrong) - this can be disheartening for a kid - you want to prepare them for this.

That's all I can think of for now.


What makes imperative programming easier or harder to learn? In my experience, people who have programmed before, whether they're professional or not, almost always consider imperative programming to be obvious. They're usually skeptical that a concept such as variable assignment could be difficult to learn.

On the other hand, in my limited experience (teaching Programming 101, and with people learning to write simple scripts), students who are beginning to learn about programming do find the concept difficult. Given a program like

x := 2;
print(x);
if some_condition() then x := 3;

many students struggle with the concept that print(x) will not print 3 even if some_condition() is true. Writing assignment using = may make the difficulty more widespread.

Is difficulty with imperative programming correlated with certain backgrounds? For example, do students with a strong mathematical background struggle more because they have some prior concept of equality? Do students with more computer time struggle less because they're more used to the concept of a state change (even if they can't formulate it in these terms of course)?

This is a topic very close to my heart.  I think that the skeptical attitude you've alluded to simply comes from the fact that most people were taught imperative programming first (and some were never exposed to any other paradigms at all).  Turing's Machine was easier to conceive of as a physical, mechanical device than Church's $\lambda$, and it is presumably by this historical accident that mutability rules the day almost everywhere.

I am not even remotely convinced that imperative programming is more obvious or intuitive than functional programming.  In my experience, setting values is a consistent cognitive trap for students, and one that I have to treat with great care.  My very first unit for AP is modeled rather loosely after Tom Rogers' phenomenal opening AP unit, Java Ain't Algebra, which takes exactly this issue head on.

In my (by now heavily modified) version of Roger's mini-unit, I make explicit that values can change, spend time tracing them, show why x = 4 + 7 is not the same as x - 4 = 7, and spend a lot of time making clear that the programmer's

=

is only barely related to the mathematical

$=$.

We also begin to explore the runtime stack.

Teachers often miss that this even needs to be covered because, once they are thoroughly inculcated in imperative programming, it can become hard to even see why this is hard in the first place.  The variable x was 4, but now it is 5.  What could be simpler?

But of course, students exposure to variables prior to CS comes from algebra.  And in algebra, when we say that $x + 3 = 7$, we mean that $x = 4$, and it cannot suddenly become $5$.  We can solve for values, but we cannot alter them.

Here's the takeaway: if we, as teachers, don't make explicit how very different it is to be able to change values, a certain percentage of students don't ever fully pick up this idea.  They'll get hazy bits and pieces of the idea, but have trouble operating, and ultimately fall behind.

In my experience, they don't appear to get noticeably lost until far later in the year, but by then, it is very hard to get them back on track.  (When I take on a new tutee in the months leading up to the AP test, this is one of the first areas I check if they seem generally lost.)  I have also come to believe that this is one of the key ideas that most CS teachers miss, and is responsible for a substantial portion of computer science's very bimodal results with students.

There is a real cognitive load to considering not the value of x, but the value of x right now, and having to both track that value and figure out when to change it.

In spite of what this all sounds like, I'm not suggesting that functional programming is necessarily easier; it has its own cognitive load, since suddenly we are contemplating many, many simultaneous x's taking place during recursive calls.  It's almost as if learning to talk to something as alien as a computer is always going to be a bit tricky :)


Is there a good textbook for writing an interpreter in an imperative language? Can anyone recommend a good textbook for writing interpreters (not compilers) that don't use languages like Scheme or Haskell?

For the "intermediate code" version of an interpreter there is no finer example in a small book than On Pascal Compilers by Per Branch Hansen. You need to be able (or a least willing) to read Pascal of course.

This book is a rare instance of CS Literature. Hansen is one of the masters.

The way the code in the book is developed you actually see the difference between compiling and interpreting as he does "code generation" to an intermediate language and then provides a separate interpreter for that language. So you see what you need to do to get to the point at which interpretation is efficient and then see how the interpreter part actually works.

The book is out of print. Check around for a used copy. Amazon currently has it a bit cheaper than Abe Books. If you have a good University Library nearby they may have it. You might also be able to get a copy from interlibrary loan that is supported by most libraries.


How to teach so that your student doesn't feel stupid? I'll start by admitting I'm not a teacher. But I am a professional computer programmer with over 20 years of experience and a BS in computer science. I'm also a dad. My daughter is 9 years old and is about to finish 3rd grade.

She does very well in school, her favorite subject is math and for the last year she's participated in a computer club. She enjoys it immensely and is at the top of her class there -- but no thanks to me.

I've tried to talk to her about programming many times, but somehow it just doesn't work. I don't push it either. Recently she made her way into a programming competition final, and we tried to study the previous year's questions for practice. It was difficult. For some reason she kept getting discouraged.

I talked about this to my wife who is also a computer programmer (hey, it runs in the family!) and with whom I've also always had problems whenever I tried to explain her something programming-related. She helped me put the problem into words - at least somewhat.

The idea is that I somehow make it sound... too easy? Like it should be obvious. But when it doesn't immediately click, it makes the listener feel stupid. And that's when learning stops and inecurities kick in.

I do try to be as encouraging as I can. I'm never impatient, I don't chastise (or give any negative feedback at all) and if the first explanation doesn't click, I try to come up with another and another and another. But when you know the subject very well then it's hard to imagine what it's like for someone who doesn't, and to understand just what doesn't click -- especially if they can't explain it themselves.

Atr there any tricks or methods that can help me here? I'd love to teach the subject that we both love to my daughter, but this is an obstacle that I just don't see how to overcome.

The idea is that I somehow make it sound... too easy? Like it should
  be obvious. But when it doesn't immediately click, it makes the
  listener feel stupid. And that's when learning stops and inecurities
  kick in.

This reminds me of the first time I was teaching an intro to programming class and I was going through a live demo of how some code worked. I mistakenly had an error in my code and got a compilation error. One of my students gasped and said, "You get those too?!"

Previously, it hadn't occurred to me that students thought that people who are "good" at programming didn't get errors. They thought there was some inherent quality that I had that prevented me from making errors like they did.

I'd recommend modeling the problem-solving process. Try doing one of the problems yourself and just let her watch and ask questions. Think aloud and describe everything that goes through your head. Even try explaining different approaches you might consider in solving the problem. It helps demystify the problem solving process of programming when novices get to witness your thinking (and debugging) process.


Programming language for teenagers I have been asked to give an introductory programming course for kids between 14-15 years old. Scratch seems like a good option for young children, maybe up to 12 years old. Python, is also a good language for beginners.

I need help from educators to choose between the two options for the mentioned age group. I'm afraid that Scratch might be too childish for them, while Python might be too complicated.

Update

Basically, the course will meet once a week. However, I have relative liberty in deciding how long the session is and how many weeks the course will be. Actually feedback in this regard is also appreciated. I want the session to be long enough to be productive, but not boring long. My initial thought is meeting for 1.5 hours each week for 6 weeks, and then deciding whether follow up course is a good idea.

I can't say much about the background of the kids. This is part of an extra-curricular school that meets every weekend, and I volunteered to give a programming course to the children to make them more interested in technology.

Update2

The age range was a bit different from expected. The kids were between 10-15 years old.

I started the course with Python and used Turtle library to have a visual output. The kids had some progress, but I felt it was slow and it was a bit hard for some of them to grasp some basic concepts.

After five or six weeks, I decided to switch to Scratch. The progress rate improved significantly. However, a few of the kids who were good with Python complained that Scratch is a language for little children that you can't do 'real' things with. It's definitely hard to please everyone.

I highly recommend checking out a language called Processing. Processing is designed for novices, and makes it easy to create visual and interactive programs without a ton of boilerplate.

Here's an example Processing sketch:

void draw() {
  ellipse(mouseX, mouseY, 25, 25);
}

This is a full program that draws a circle wherever the mouse is, 60 times per second.

Related:

Using Processing as an entry point in an Introductory Course
Programming languages specifically designed for beginners
The order of subjects in beginner's curriculum
Order to Teach Topics in an Intro Programming Class
Make it easier, and quicker to get to the start

Shameless self-promotion: I wrote a series of tutorials for Processing available here. I'd love to talk more about using these in a curriculum.


Putting feedback comments on source code when grading My students currently submit their code in Bitbucket and create a pull request. Bitbucket has a code review tool that allows me to create comments tied to specific lines in the code. I really like this. However, it only lets me comment on the diff, so I can only comment on code in the most recent commit. I want to be able to comment on the entire source file. Is there a tool that lets me do that in a similar fashion?

The diff is between the most recent commit and the start of the branch. It's not just the diff of the last commit, it's every commit (stacked on top of each other) since the branch's origins.

If that weren't the case, it'd be nigh impossible to provide meaningful feedback to a code review for a branch's pull request.


Ways to advance the field of computer science education as a non-researcher I understand, as a model, how a researcher at a university can advance the entire field of CS Education.  Less clear to me, however, are methods available to teachers in the field who do not have doctoral degrees, much less a publication history.  Beyond posting on this website, what ways are available to advance the field of CS education?

Actually

(a) you don't need a doctorate to do research,

(b) most university faculty don't do research in CSEducation, but in CS,

(c) most conference committees don't care much about the formal credentials of those who submit papers to the conference. SIGCSE, for example, has quite a lot of work by people without doctorates.

However, what you probably do need is contact and communication with like-minded people with an interest and some writing ability.

I hope this doesn't become just a list of options, but there are quite a few.

Probably the most productive line for a person at a smaller institution is to try to make contacts with those writing and doing research in a field that interests you. If you express interest you might get included in their normal communication mechanism. Often people need to work remotely from colleagues, so you have no real disadvantage there. Find a paper that interests you and write to its authors to ask what they might be working on that you might contribute to.
If you are in an area with quite a few educators you might try to found a discussion group among teachers in similar positions. It could lead to bigger things, but you need to be able to keep up with what is going on through reading. Once established you might be able to invite a university educator to one of your meetings, spreading your contacts. You might also be able to extract an invitation visit any working groups that the University might have.
Try to find a way to go to either a national or one of the regional conferences of educators. You will meet a lot of people. The Consortium for Computing in Small Colleges holds a conference annually in each of the major regions of the US. I expect they will be happy to ignore the fact that you might be a secondary educator.
Get involved in APCS, not just as a teacher, but as a contributor. One option, if you have the time is to become an AP grader. This is an annual event in which you will work hard, but also meet a large number of people interested in CS Education, some from the Secondary Level and some from Universities.
One of the groups that should probably interest you is the people who write Pedagogical Patterns. These are based on experience, not research, and go through a vetting process to validate them to the community. Among other things they do is help one another write (shepherding) and a formal process of feedback at the periodic conferences (workshopping). Any pedagogical pattern you are likely to see has been re-written a dozen times with feedback from, perhaps, a dozen to twenty people. It is a vibrant community.


How important is "delivering the content" of a course? In most fields instructors spend a lot of time on the Content of a course. Often this is phrased as Delivering Content, or Completing the Syllabus. The traditional picture, whether valid or not, is an instructor (single) broadcasting Content to students (multiple). I wonder if this is a common view of CS education.

In a course like Data Structures, there a lot of things (content) that the student has to learn: Stacks, Sets, Trees, ... along with common algorithms. Normally there is a syllabus that lists all these things in some rational order. "Covering it" is a sort of meta-constraint (or sometimes a hard constraint) on the instructor.

In the compiler course, the Content is more about technique than facts, of course, but those techniques possibly are the content: scanning, parsing, ...

So, I guess the question that I would most like advice on here is:

  If you could order your goals in a typical undergrad course where
  would "Deliver
  the Content" fit? High, Low? What, if anything, would be above it?

What would be the effect on your students if you move that goal up? down? remove it altogether?

Another aspect of this is how much control does/should the professor have in the flow of the course; especially in content delivery? Absolute? None? What balance works for you?

Let's consider your Data Structures course example. The material from there is used throughout CS, and more advanced courses probably expect you to have completed Data Structures already, and will assume understanding. If the instructor never actually introduces to all the data structures that the syllabus lists, then your later course will be assuming knowledge that the student doesn't necessarily have.

It depends what exactly you mean by not making content King—if you simply don't teach some of the material and don't mention it much, then your students won't know it. However, something to consider:

What is the goal of your course? To ensure that your students know the material so that they can build on it, or to encourage your students to apply their knowledge?

If you want students to be able to apply what they know to unfamiliar concepts without your support, then definitely don't spoonfeed everything. However, it might be wiser to introduce all of the standard content, and then allow them to apply their knowledge on more obscure concepts.

As an example, you could first introduce an array, then ask about a bitmap (which you might not cover in your instruction, so you can test them).
Will the material be needed later on? Would it be problematic if students didn't learn all the material? If so, perhaps it's best to cover the content in your class to ensure that they do understand.

In an ideal world, you might give students a problem, and let them explore solutions to it rather than actually covering the content directly. For example:

  How can we represent pairings between two variables in a data structure? Can it be done in $\mathcal{O}(1)$ time?

Instead, a lot of the time, the content is just 'fed' to the students directly.

  Here is a hash table. It does X, Y and Z. It is useful because W.

Given a large amount of time, actually rediscovering some solutions to common problems would help your students to think critically and understand why certain design choices have been made in CS. But you could spend years rediscovering things that are already known, and sometimes just telling allows you to move on more quickly.

Removing 'the content' completely from the course would essentially render it pointless—if there's no goal ("in this course, we will learn X"), the course wouldn't really seem to help anyone.

As a summary of my views: delivering the content is practically a requirement given the time constraints of most courses, rather than letting students investigate things for themselves. Perhaps changing this would provide some benefits, but the current system has emerged because it's pretty efficient as passing on knowledge, even though some students don't benefit as much as they could.


Which are common misconceptions about code execution? How to efficiently debug my student? I may tutor a student who just started learning "school C", by which I mean that strange kind of C seen only on school books (and that in my opinion "cripples the mind", so to say, but I digress). I need to quickly understand her misconceptions, as she is saying that she has many doubts, she says "the char function", "the for function", "no idea what ++ is" and the like.

She looks brilliant nonetheless, besides having great confusion on cs things (and a decreasing engagement of course), therefore I'd prefer a very direct and practical way of getting to her errors, not spending a lot of time repeating concepts that might bore her. I'm quite good at understanding my pupils' mind maps given their answers and fix them but not so good at creating questions/problems that pose the right challenges and let the misconceptions provoke errors in their solutions, mostly because it all seems too simple to me whereas it looks like many students find this topic complex. The only thing that comes to my mind is generating a lot of situations hoping to see her wrong somewhere, clearly not a systematic approach.

Let's say, in our terms, that I don't know well how to identify the corner cases that I ought to be testing and I feel like risking to follow only the happy paths of her thought processes.

For example, I read somewhere that a common misconception is to think that given something like while (relation) { ... } then the student thinks that whenever the relation becomes false something happens (break? I don't know), anywhere in the midst of the block. (I have a compelling feeling of why this specific case might happen).

What are, from your experience (hoping not to make the question too subjective), or from literature, the most common misconceptions and false beliefs that beginning students have? What problems can I give her to extract the most errors?

I think both reading and writing problems, from tracing the execution to fizzbuzz or rainfall style, are there other important exercise types that I shouldn't forget? Anything without code?

Sorry if the question seems boring, I looked for examples a lot, found only a few articles but not really satisfying. Seems that I couldn't find a good catalog of misconceptions and relative inquire methods.

I may add to this as ideas occur to me, but here is a starter version.

You don't state the general academic level of the student, so I'll assume secondary school or beginning university. The student has studied Algebra at least and has some background in math.

The second really big misconception is that a program is just like math. In particular, in C, the misconception that a statement like

  x = y + 1;

is an equation to be solved, rather than an operation to be performed. But this is based on the first misconception that a "variable" in algebra is the same sort of thing as a "variable" in programming (in C like languages). In fact, in algebra, a variable doesn't vary, it is a fixed but possibly undetermined value. In C, the value can vary. In algebra, the above represents a relationship. In programming it is an operation. So, first, solve those two possible misconceptions with examples, exercises, and explanations as necessary. Once you do that ++y makes some sense as an operation.

The third big misconception is just that a computer executes an algorithm, which is a sequential execution of defined steps. The program counter, PC, keeps track of the "current state" of the algorithm. In the while loop, the test only gets executed when the PC comes to it in an unrolling of the loop into a sequence of operations.

My personal preference is to teach "variables" as "references to values" not as contents of memory locations. So

  x = 5;

means that x refers to 5, not that it is 5. Then you avoid the problem that if the next statement is

  x = x + 1;

that the student thinks that five has magically become six. It is just that now x refers to a different value.

Caveats.

Note that I'm assuming C-like languages. In lisp-like languages algebra variables and lisp "variables" are actually the same - undetermined/unspecified but immutable values. Also in Fortran IV, you could actually make five magically turn into six. History lesson there, though.

And, of course, modern high performance computers aren't strictly sequential anymore, with speculative execution at branch points.

In fact, with a bit of finesse you can discuss a C program with no reference to any actual machine at all. It defines an algorithm. Full Stop. The finesse part is just about the PC mentioned earlier.


Algorithm Design challenges In my course we discuss algorithms (greedy, dp, div & conquer, etc.) and efficiency. Do you have any experience with assignments that consider also time of execution as a criterion for grading? Do you use any tools for measuring execution time?

Execution time is unreliable due to variations in hardware and, especially, operating systems. Paging and multi-level cache can make such things worthless. That is why theoretical measures are used.
The actual execution time depends on the specific implementation of the algorithm, not its structure. Implemented poorly in Java it will run slower than if implemented well in C (and conversely). Paged operating systems, such as Unix and its variants (and others) put an extra load on algorithms at scale. Multi level cache can speed things up but vary between processors.
Efficiency of an algorithm is a theoretical concept and so is measured theoretically, perhaps by counting comparisons. This might mean something if you compare two algorithms on the same hardware, but may even be misleading if the implementation causes, for example, page thrashing.
In addition, most modern OSs are multiprogrammed and a given program has little control over whether it has complete control over the processor while it executes, or even over a single thread.
But most operating systems will have a way to give you the actual running time of the execution of a program. A few thousand executions will give you an accurate picture for that algorithm on that set of inputs, but might vary widely if you double the inputs.
See the Linux date command for example. You can integrate it into a shell script that executes a program a few thousand times and get some averages.