runestoneinteractive / runestoneserver Goto Github PK
View Code? Open in Web Editor NEWInteractive books for computer science and mathematics
Home Page: http://runestoneinteractive.org
License: Other
Interactive books for computer science and mathematics
Home Page: http://runestoneinteractive.org
License: Other
Actually every time you press the grade button another copy of the program in its codemirror box is created. This seems to be a regression....
Since chapters and such are constantly being improved, and to allow for bug fixes the index should be saved so a book can be rebuilt.
May also need to allow the instructor to select a group of assignments
Hello,
I'm learning python by interactivepython tutorial. I've found that ActiveCode or module image have some bugs.
For example, if I type this:
x = (p.getRed() + p.getBlue() + int(p.getGreen))/3
it's ok,
but if I type this:
x = (p.getRed() + p.getBlue() + p.getGreen)/3
I get an error, saying:
TypeError: unsupported operand type(s) for Add: 'undefined' and 'undefined'
It also has some other bugs. It would also be good if users could download the image module, since it would be easier and faster to try many things on your own computer than on internet.
Or you could use some existing module for the same purpose (like Tkinter or sth, I don't know with which you can change images like with your module).
Or you could at test some exercises with your own solutions and delete those that can't be solved because of bugs - it's really annoying for newbies, since they can stuck for hours with some problems, even if it's not their fault.
By the way, here: http://interactivepython.org/courselib/static/thinkcspy/MoreAboutIteration/moreiteration.html
First questions under "Check your understanding" are repeated in next chapter so they should be deleted.
The recursion chapter is missing the activecode popup windows for doing and submitting exercises.
While going through How to think like a computer scientist chapter 2 when i went through the 3 and 4 problem i noticed a problem.If we input 1459 as time and 50 hrs then it gives 1461 instead of of 1501.The 4 program gives wrong output for input 3(day) and 67(stay).Please check the code and correct it.
The end of chapter exercises in the recursion chapter are out of whack. there are duplicate numbers as well as repeated numbers.
All of the exercises appear to refer to a “Rectangle” class which does not appear to have been implemented anywhere in the book.
We should have exercises for the fraction class as well as adding some exercises for Rectangle
Lists chapter, activecode: 3 (chp09_02):
")" missing at the end of line 5.
I am new to programming and really appreciate the resources you guys provide but I did have a question. In the More About Iteration section there is a module that is used called image.
Sometimes I will try to write code up in a text editor and just run it, instead of using the online active code. This time I tried to do that and when I used "import image", I got a a message saying that this module does not exist. I was assuming all the modules were standard libraries provided by Python.
I googled the image module and found http://www.pythonware.com/library/pil/handbook/image.htm. This looks like the same module except the syntax was slightly different. For one the module name is capitalized (Image...not image), and the syntax is totally different.
I understand things change but I just wanted to verify that this is the case and I'm not doing something wrong. I was having trouble installing the module as well because I had a 64 bit version of Python2.7 and the module was for 32 bit (I think). Is this the same image module you guys are teaching? Did the designers of this module change their syntax? Some of the modules are not in the standard library, is that correct? Thanks guys!
question 3.2.1 has formatting problems
it should not have things like "
in it.
I found a mistake in a tutorial, here:
http://interactivepython.org/courselib/static/thinkcspy/Strings/strings.html#optional-parameters
It says:
The call find2('banana', 'a', 2) now returns 3, the index of the first occurrence of ‘a’ in ‘banana’ after index 2. What does find2('banana', 'n', 3) return? If you said, 4, there is a good chance you understand how find2 works. Try it.
Instead of 4 it should say 3.
As far as I concern in Check your understanding 9.13.2 should be used insert method instead of add.
Hi there,
This book has been a great help but some of the self-check exercises in Problem Solving with Algorithms and Data Structures doesn't evaluate. This came about when I was attempting some of the exercises in the Sorting and Searching section.
Without the base as the parameter a weird error message is given about the lack of constructor for unknown
Hi,
I'd log in to the course and find on the top and bottom of the page saying that I am not logged in.
Also, I think it would be a good idea to not to force choosing a course on registration since once you did, you'd be brought to that course page upon log in. Which makes it difficult to navigate to other courses.
It would be nice to have an assessment question that asks the student to write a function. The assessment could utilize unit test to capture the results to the log as well as to provide feedback to the student.
Hello, I found a bug in a tutorial (and now I'm sure it's a bug, since I tried it in IDLE).
http://interactivepython.org/courselib/static/thinkcspy/Dictionaries/dictionaries.html
In ActiveCode 13: if I click Run, I get 3, 3 instead of 1, 0.
print(matrix.get((0,3)))
print(matrix.get((1, 3), 0))
Whatever key you put in it, it always returns value of key (4,3).
It might be cool for students to be able to see how they compare in their performance on assessment questions compared to their classmates.
I'm teaching introduction to computer science at the University of Toronto Scarborough Campus, and one of my students pointed out an error in your description of readlines(n). In your text it says: Returns a list of n strings, each representing a single line of the file. If n is not provided then all lines of the file are returned.
However, according to docs.python.org: f.readlines() returns a list containing all the lines of data in the file. If given an optional parameter sizehint, it reads that many bytes from the file and enough more to complete a line, and returns the lines from that.
This caused some confusion when the students tried to strip off the first 3 lines of text from a document by using readlines(3), but were confused when they only got 1 line.
How to Think Like a Computer Scientist
8.11.1: What is printed by the following statements
code:
s = "ball"
r = ""
for item in s:
r = s.upper() + r
print(r)
answers:
a) Ball
b) BALL
c) LLAB
Think you want to use something different inside for loop. Check it.
the example "ActiveCode: 7 (intro_8)" on http://interactivepython.org/courselib/static/pythonds/Introduction/introduction.html#review-of-basic-python
cannot be run interactively at the python prompt, unlike other examples in this section. It is not made clear why that is so.
Hi there,
This book has been a great help but some of the self-checks exercises in Problem Solving with Algorithms and Data Structures doesn't evaluate. This came about when I was reading the Sorting and Searching section.
This would look something like the listassignments interface but would show the tries and statistics for each assessment question
After yesterday's commits, any page with ActiveCode on it gives the error "Assertion Failure (see console log for backtrace)," and neither ActiveCode nor CodeLens will run. After quite a bit of time trying to figure out where the logs are, I can't seem to find anything.
After getting the error, find / -mmin -1
doesn't show anything that looks like a log, and any place I thought to look (/var/log/apache2, nohup.out, the webserver errors page) had nothing recent.
The following code gives the confusing error message: TypeError: Cannot read property 'constructor' of undefined. For introductory python learners this is not helpful.
def foo(x):
y = y + 10
return x
foo(5)
The following code gives the confusing error message: TypeError: Cannot read property 'constructor' of undefined. For introductory python learners this is not helpful.
def foo(x):
y = y + 10
return x
foo(5)
6.7.1
this code does NOT give the same output as the other code
if x < 0:
print("The negative number ", x, " is not valid here.")
if (x > 0):
print(x, " is a positive number")
else:
print(x, " is 0")
the answer to the question is incorrect. Only the II choice gives the
same output as the first code.
"1.2.2: What is the difference between a high-level programming language and a low-level programming language?
a) It is high-level if you are standing and low-level if you are sitting.
b) It is high-level if you are programming for a computer and low-level if you are programming for a phone or mobile device.
c) It is high-level if the program must be processed before it can run, and low-level if the computer can execute it without additional processing.
d) It is high-level if it easy to program in and is very short; it is low-level if it is really hard to program in and the programs are really long."
Since assembly and other low level languages other than machine code require compiling answer C is a tad incorrect as the code can not be directly executed without compiling, which would be additional processing from my understanding.
Also
"As you might infer from the name high-level language, there are also low-level languages, sometimes referred to as machine languages or assembly languages. Loosely speaking, computers can only execute programs written in low-level languages."
Only machine language can be executed which is what is generated by interpreters and compilers unless there has been some major change in computing that allows a computer to execute anything other than 0s and 1s.
I point this out because it falls back on the flaw of teaching physics at least in the United States. Teaching something incorrect like centripetal force for an easy to grasp yet wrong explanation then later teaching the correct information at a later date. It has been proven time and time again that is is better to correctly teach it the first time than to unlearn and reteach.
Hello, I just wanted to let you know that the Self Check question regarding Shell Sorts in the Sorting section of your online Python Data Structures book says that all of the answer choices are incorrect. Please fix it whenever you have some time and have a good day!
Can you please upload video in a Youtube or Vimeo format? The current format won't let me play videos for longer than 5 minutes. The videos keep getting stuck in the same place. I've tested it in different browsers.
For example show the steps in merge sort by dragging and dropping list elements to do the appropriate swaps,
Some students have reported that even after logging in just a few minutes prior, they are not able to save their program.
The only time this should happen is if the login session has expired.
I've seen this happen with notebook users who leave a tab open for a long period of time and then start to work in an activecode window. Their session has expired, but they haven't refreshed the page so the page doesn't know its expired. When they click the button to save the ajax call fails.
I'm going to add better error messages as a first step but I would love to hear any suggestions for how to handle this the right way. That is knowing that the session has expired before I even make the ajax call. -- or even when the user first starts to type in the window.
In addition to multiple choice add a simple question type where the student can enter a short -- one or two word answer that can be checked using a simple regular expression
the gradeassignment view does not need to include a javascript check for login status. This precipitates an unrelated error because the jquery.timeout plugin is not incluced on this page.
Clean this up as follows:
Move the actual call to check the login/logout status to template.html.
Tighten up the try/catch block in the getuser function to not include so much stuff.
B.) Recursion ex 3 : “Create a module named seqtools.py. Add the functions encapsulate and insert_in_middle from the chapter. Add tests which test that these two functions work as intended with all three sequence types.”
What are these “encapsulate” and “insert in middle” functions? They do not reference anything from said chapter, or from anywhere in book itself as far as I can gather.
C.) Recursion ex 10: “Use help to find out what sys.getrecursionlimit() and sys.setrecursionlimit(n) do. Create several experiments similar to what was done in infinite_recursion.py to test your understanding of how these module functions work.
What is this “infinite_recursion.py” script?”
Using some graphviz libraries this would not be too hard.
The Makefile ought to have an option for choosing what the project name for custom courses is, as whenever I make it, I have to edit the HTML files to change Your Project Name Here to our course name.
Strings ex 18: “Write a function descramble that takes a message that is scrambled using the picket fence algorithm as discussed in class. Try exchanging messages with a friend and the secret message provided below:”
The picket fence algorithm needs to be described in the chapter, or in the exercise in order for non class readers to do this exercise.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.