Table of Contents

Homework 1

Basics

A first homework to practice the basics from the first two labs; definition of variables, vectors, matrices, functions, working with strings and data structures.

Your task is to define the variables and functions as described below.

Your Task

Define the following objects as described in the template;

  • variables x, y, s, and δ
  • vectors primes and fives
  • tuple tup
  • matrices A, B and 3D tensor C

Implement the following two functions as described in the template;

  • The function normal for the calculation of the probability density value of the Normal distribution.
  • The functions count_letters for counting letters in text.

Tips for successful solution:

  • Define all objects (variables and functions) directly in the global scope of the submitted file “hw.jl”. (Don't enclose them into modules or into other functions.)
  • When defining variables, check that the data type is correct, including a correct type of the elements in case of data structures.
  • * Funkce count_letters by měla správně spočítat i písmena s nulovou četností. Stačí počítat písmena anglické abecedy. Počítejte velká a malá písmena dohromady a do slovníku indexujte malými písmeny.
  • The function count_letters should correctly count letters with zero occurrences as well. Count uppercase and lowercase letters together. Index into the dictionary using lowercase letters.
  • Don't import disallowed packages.
  • (You can write δ in VSCode by typing “\delta” and hitting tab. Or just copy it.)
courses/b0b36jul/en/hw/hw1.txt · Last modified: 2025/10/02 13:24 by soldasim