Course detail

Basics of Programming

FSI-SZPAcad. year: 2027/2028

The course provides an introduction to the C# language using the Visual Studio IDE. Students are introduced to basic concepts such as statements, variables, data types and others. Students are also introduced to the basics of object-oriented programming.

Language of instruction

Czech

Number of ECTS credits

4

Assignment to study programme types

Bachelor's

Mode of study

Not applicable.

Learning outcomes of the course unit

Not applicable.

Entry knowledge

Computer basics.

Rules for evaluation and completion of the course

The assessment consists of points for a semester project (presentation of a working C# program, 70 %) and points for individual assignments given during the semester (30 %). To obtain the credit, students must earn at least 50 % of the semester project points and at least 50 % of the total points.

Attendance at lectures is recommended, attendance at exercises is compulsory. The teacher checks attendance at each exercise. Students may miss at most 2 exercises per semester. Teaching follows the weekly timetable; the exercises build on the lecture topics according to the syllabus. The way missed classes are compensated is determined by the teacher.

Aims

The aim of the course is to teach students the basics of creating simple applications in C# in the Visual Studio development environment and how to formulate algorithms for solving problems.

After completing the course, the student will be able to:

– create, run and debug a console application in Visual Studio,
– use variables, data types, operators, conditions and loops,
– distinguish between value and reference types and work with arrays and collections,
– decompose a problem into methods and implement a simple algorithm,
– load and save data in a text file and handle invalid user input,
– design a simple class with a constructor, methods and properties.

Study aids

Basic literature:

PRICE, M. J. C# 12 and .NET 8 – Modern Cross-Platform Development Fundamentals. 8th ed. Birmingham: Packt, 2023.
Microsoft. C# documentation [online]. Available from: https://learn.microsoft.com/dotnet/csharp/

Recommended literature:

STELLMAN, A., GREENE, J. Head First C#. 4th ed. Sebastopol: O'Reilly Media, 2020.
ALBAHARI, J. C# 12 in a Nutshell. Sebastopol: O'Reilly Media, 2023.

Prerequisites and corequisites

Not applicable.

Basic literature

Albahari, J.: C# 10 in a Nutshell: The Definitive Reference, O'Reilly Media; 1st edition (March 15, 2022), ISBN 978-1098121952. (EN)
Oficiální online dokumentace jazyka C#: https://learn.microsoft.com/en-us/dotnet/csharp/ (EN)
Microsoft. C# documentation [online]. Available from: https://learn.microsoft.com/dotnet/csharp/
PRICE, M. J. C# 12 and .NET 8 – Modern Cross-Platform Development Fundamentals. 8th ed. Birmingham: Packt, 2023.
Price, M.: C# 11 and .NET 7 – Modern Cross-Platform Development Fundamentals; Packt Publishing; 7th ed. edition (November 8, 2022), ISBN 978-1803237800.   (EN)

Recommended reading

ALBAHARI, J. C# 12 in a Nutshell. Sebastopol: O'Reilly Media, 2023.
STELLMAN, A., GREENE, J. Head First C#. 4th ed. Sebastopol: O'Reilly Media, 2020.

Classification of course in study plans

  • Programme B-MAI-P Bachelor's 1 year of study, winter semester, compulsory

Type of course unit

 

Lecture

13 hours, optionally

Teacher / Lecturer

Syllabus

1. Introduction: the C# language and the .NET platform, the Visual Studio development environment, first program. Variables, data types, operators.
2. Data types, console input and output. Conditions, switch.
3. Loops (for, foreach, while, do-while), common mistakes.
4. Arrays and collections (List, Dictionary, queue, stack). Introduction to methods.
5. Value and reference types. Access modifiers. Methods – parameters, return value, ref and out, optional parameters, overloading, recursion.
6. Working with files – writing and reading, file paths, line-by-line processing. Input validation.
7. Designing a program with methods – problem analysis, required data, splitting into methods.
8. Classes and objects – constructor, instance methods, static and instance members.
9. Fields and properties – get, set, value checking.
10. Designing a class by example.
11. Cooperation of several classes – multiple constructors, objects as parameters, static members.
12. Problem solving.
13. Presentation of semester projects.

Computer-assisted exercise

26 hours, compulsory

Teacher / Lecturer

Syllabus

1. Installing and configuring Visual Studio, first console application, variables and operators.
2. Console input and output, conditions – solving simple problems.
3. Loops – solving simple problems.
4. Working with arrays and collections, first custom methods.
5. Value and reference types, visibility, methods with parameters, method overloading.
6. Working with files.
7. Step-by-step implementation of the designed program split into methods.
8. First custom class.
9. Classes with fields and properties, value checking.
10. Designing and implementing a class for an assigned example.
11. A program with several cooperating classes.
12. Problem solving – individual solution of a complex problem, semester project consultation.
13. Presentation of semester projects.