User contributions for WikiSysop
Jump to navigation
Jump to search
27 August 2025
- 13:2913:29, 27 August 2025 diff hist +8 m Stateful parsing No edit summary
- 13:2813:28, 27 August 2025 diff hist +17 m Stateful parsing No edit summary
- 13:2813:28, 27 August 2025 diff hist +17 m Exceptions and bug handling No edit summary
- 13:2713:27, 27 August 2025 diff hist +17 m String manipulation No edit summary
- 13:2713:27, 27 August 2025 diff hist +17 m Pseudocode and comments No edit summary
- 13:2713:27, 27 August 2025 diff hist +17 m The path and simple file reading No edit summary current
- 13:2613:26, 27 August 2025 diff hist +8 m Python recap No edit summary
- 13:2413:24, 27 August 2025 diff hist +9 m Python recap No edit summary
- 11:2411:24, 27 August 2025 diff hist +98 m The path and simple file reading →Exercises to be handed in
- 10:1310:13, 27 August 2025 diff hist +1 m Python recap →Exercises to be handed in
- 10:1310:13, 27 August 2025 diff hist +368 m The path and simple file reading →Exercises to be handed in
26 August 2025
- 12:0512:05, 26 August 2025 diff hist −11 m Functions No edit summary
- 11:3611:36, 26 August 2025 diff hist +4,178 N Functions Created page with "__NOTOC__ {| width=500 style="font-size: 10px; float:right; margin-left: 10px; margin-top: -56px;" |Previous: Regular Expressions |Next: Advanced Data Structures and New Data Types |} == Required course material for the lesson == Powerpoint: [https://teaching.healthtech.dtu.dk/material/22113/22113_04-Functions.ppt Making functions]<br> Video: [https://panopto.dtu.dk/Panopto/Pages/Viewer.aspx?id=f509116f-48e5-445b-bf6e-af27012ba23f Functions in Python] Monday<br>..."
- 11:3511:35, 26 August 2025 diff hist +4 m Stateful parsing No edit summary
- 11:1911:19, 26 August 2025 diff hist 0 m Stateful parsing No edit summary
- 11:1911:19, 26 August 2025 diff hist +3,402 N Stateful parsing Created page with "__NOTOC__ {| width=500 style="float:right; margin-left: 10px; margin-top: -56px;" |Previous: Exceptions and Bug Handling |Next: Lists |} == Required course material for the lesson == Powerpoint: [https://teaching.healthtech.dtu.dk/material/22101/22101_08-StatefulParsing.ppt Stateful Parsing]<br> Video: [https://panopto.dtu.dk/Panopto/Pages/Viewer.aspx?id=fe50507e-9009-49b1-a3a8-af27012d8cdf Stateful Parsing]<br> Video: [https://panopto.dtu.dk/Panopto/Pages/Viewe..."
- 11:1411:14, 26 August 2025 diff hist +1,489 N Example code - Exceptions Created page with "== Determining input type == How to determine the input with try/expect. This is not really how it is done in practice, but it is still good to understand the ideas, because sooner or later you run into a situation where parts of this is useful. <pre> inputstring = input("Enter something and I will guess what it is: ") try: # This assignment will succeed mytype = 'string' # This may fail, in such case our exception handler is called result = float(inputst..." current
- 11:1411:14, 26 August 2025 diff hist +4,093 N Exceptions and bug handling Created page with "__NOTOC__ {| width=500 style="float:right; margin-left: 10px; margin-top: -56px;" |Previous: String manipulation |Next: Stateful parsing |} == Required course material for the lesson == Powerpoint: [https://teaching.healthtech.dtu.dk/material/22116/22116_05-Exceptions.ppt Exceptions and bug handling]<br> <!-- Video: [https://panopto.dtu.dk/Panopto/Pages/Viewer.aspx?id=d230fcd7-c06c-414e-a14d-af27012e22f6 Exceptions]<br> Video: [https://panopto.dtu.dk/Panopto/Pag..."
- 11:0711:07, 26 August 2025 diff hist +1,131 N Example code - Changing tabs to spaces Created page with "== Replacing tabs with spaces == As you may have discovered by now, Python is very sensitive about mixing tabs and spaces in the indentation. This program discovers all the tabs and makes them into spaces. You can decide how many spaces a tab should be.<br> The program is meant to work in a Unix environment, and Jupyter Notebook will tend to make it superfluous. <pre> filename = input("Filename: ") spaceno = int(input("Number of spaces instead of a tab: ")) # Make a st..." current
- 11:0711:07, 26 August 2025 diff hist +11 m String manipulation →Required course material for the lesson
- 11:0411:04, 26 August 2025 diff hist +6,443 N String manipulation Created page with "__NOTOC__ {| width=500 style="float:right; margin-left: 10px; margin-top: -56px;" |Previous: Pseudocode and comments |Next: Exceptions and bug handling |} == Required course material for the lesson == Powerpoint: [https://teaching.healthtech.dtu.dk/material/22116/22116_04-String.ppt String manipulation]<br> Resource: Biological knowledge needed in the course<br> Resource: Example code - Input Output<br> Resource: [https://teaching.healthtech.dtu.dk/mater..."
- 10:5410:54, 26 August 2025 diff hist 0 m Pseudocode and comments No edit summary
- 10:5210:52, 26 August 2025 diff hist +124 m Pseudocode and comments →Exercises to be handed in
- 10:4010:40, 26 August 2025 diff hist −89 m Pseudocode and comments →Exercises to be handed in
- 10:2310:23, 26 August 2025 diff hist +561 m Pseudocode and comments →Exercises to be handed in
- 10:2110:21, 26 August 2025 diff hist +780 m Pseudocode and comments →Exercises to be handed in
- 08:5608:56, 26 August 2025 diff hist +3,091 N Collection of files Created page with "__NOTOC__ Last updated: September 1, 2025<br> Warning: This is not complete or correct yet. == Files used in various exercises == To download the files to your system, just press the Shift key while you left click on the blue link. Follow the instructions.<br> You can play around with these files as much as you like. If you change or destroy them, just download them again.<br> Put the files in your course folder on your computer.<br> <!--The files have been zipped togeth..."
- 08:5408:54, 26 August 2025 diff hist −1 m Pseudocode and comments →Subjects covered
- 08:5308:53, 26 August 2025 diff hist −1 m Programme No edit summary
- 07:1207:12, 26 August 2025 diff hist −79 m Python recap →Exercises to be handed in
25 August 2025
- 19:2619:26, 25 August 2025 diff hist +572 m Pseudocode and comments No edit summary
- 19:2419:24, 25 August 2025 diff hist +152 m Python recap →Required course material for the lesson
- 19:2419:24, 25 August 2025 diff hist +5 m Pseudocode and comments →Required course material for the lesson
- 17:3717:37, 25 August 2025 diff hist +44 m Pseudocode and comments →Exercises to be handed in
- 17:3617:36, 25 August 2025 diff hist +2,275 N Pseudocode and comments Created page with "__NOTOC__ {| width=500 style="float:right; margin-left: 10px; margin-top: -56px;" |Previous: The path and simple file reading |Next: Python Input-Output |} == Required course material for the lesson == Powerpoint: [https://teaching.healthtech.dtu.dk/material/22116/22116_03-PseudoComments.ppt Pseudocode, comments and user interface]<br> Video: [https://panopto.dtu.dk/Panopto/Pages/Viewer.aspx?id=79ac24c4-603c-4a6e-9343-af2701292c8c The use of pseudocode and comme..."
- 17:3017:30, 25 August 2025 diff hist 0 m The path and simple file reading No edit summary
- 17:2617:26, 25 August 2025 diff hist +22 m The path and simple file reading →Exercises to be handed in
- 17:2517:25, 25 August 2025 diff hist +863 m The path and simple file reading →Exercises to be handed in
- 17:1117:11, 25 August 2025 diff hist +267 m Python recap →Exercises to be handed in
- 17:1017:10, 25 August 2025 diff hist −1,326 m The path and simple file reading No edit summary
- 16:4916:49, 25 August 2025 diff hist +629 N Example code - File Reading Created page with "== Numbering and printing a chunk of file == <pre> print("Numbers and prints a section of a file.") filename = input("Filename: ") fromline = int(input("From line: ")) toline = int(input("To line: ")) with open(filename, "r") as infile: # keep track of the line number linenumber = 0 # iterate over the lines in the file for line in infile: linenumber += 1 # went past the required last line if linenumber > toline: pas..." current
- 16:4916:49, 25 August 2025 diff hist +3,807 N The path and simple file reading Created page with "__NOTOC__ {| width=500 style="float:right; margin-left: 10px; margin-top: -56px;" |Previous: Python Recap |Next: Pseudocode and Comments |} == Required course material for the lesson == Powerpoint: [https://teaching.healthtech.dtu.dk/material/22116/22116_02-PathFile.ppt The path & simple file reading]<br> Resource: Example code - File Reading<br> == Subjects covered == ''with'' statement, just a simple use of it.<br> ''open'' function for opening files for..."
- 16:4516:45, 25 August 2025 diff hist −6 m Python recap →Subjects covered
- 15:2915:29, 25 August 2025 diff hist +830 m Python recap →Exercises to be handed in
- 15:2515:25, 25 August 2025 diff hist 0 m Python recap No edit summary
- 15:2415:24, 25 August 2025 diff hist +19 m Python recap →Exercises to be handed in
- 15:2215:22, 25 August 2025 diff hist −1,053 m Python recap →Exercises to be handed in
- 15:1715:17, 25 August 2025 diff hist +1 m Python recap →Subjects covered
- 15:1715:17, 25 August 2025 diff hist −146 m Python recap →Subjects covered
- 15:0515:05, 25 August 2025 diff hist +1,192 N Example code - Basics Created page with "== Decimal to Binary number converter == I am a bit unhappy about this example due to the required knowledge of binary numbers, but as such the example is great.<br> Youtube: [https://www.youtube.com/watch?v=2SUvWfNJSsM Binary numbers - watch from 2:00 to 6:00]<br> [https://en.wikipedia.org/wiki/Binary_number#Representation Wikipedia on binary numbers] <pre> print("This script converts whole numbers (integers) into binary.") # Ask for user input number = int(input("Ente..." current