Hong-Phuc Bui
2025-04-29 cddee2e624f8f2f3aab2383f37914649f540486a
3.te vorlesung
11 files added
124 ■■■■■ changed files
.idea/mam-2025.iml 8 ●●●●● patch | view | raw | blame | history
03-funktion/.idea/.gitignore 3 ●●●●● patch | view | raw | blame | history
03-funktion/.idea/03-funktion.iml 8 ●●●●● patch | view | raw | blame | history
03-funktion/.idea/inspectionProfiles/Project_Default.xml 14 ●●●●● patch | view | raw | blame | history
03-funktion/.idea/inspectionProfiles/profiles_settings.xml 6 ●●●●● patch | view | raw | blame | history
03-funktion/.idea/misc.xml 7 ●●●●● patch | view | raw | blame | history
03-funktion/.idea/modules.xml 8 ●●●●● patch | view | raw | blame | history
03-funktion/.idea/vcs.xml 6 ●●●●● patch | view | raw | blame | history
03-funktion/Inhalt.md 6 ●●●●● patch | view | raw | blame | history
03-funktion/gauss-ostern.py 48 ●●●●● patch | view | raw | blame | history
canvas-bezier/.idea/canvas-bezier.iml 10 ●●●●● patch | view | raw | blame | history
.idea/mam-2025.iml
New file
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
  <component name="NewModuleRootManager">
    <content url="file://$MODULE_DIR$" />
    <orderEntry type="inheritedJdk" />
    <orderEntry type="sourceFolder" forTests="false" />
  </component>
</module>
03-funktion/.idea/.gitignore
New file
@@ -0,0 +1,3 @@
# Default ignored files
/shelf/
/workspace.xml
03-funktion/.idea/03-funktion.iml
New file
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
  <component name="NewModuleRootManager">
    <content url="file://$MODULE_DIR$" />
    <orderEntry type="jdk" jdkName="Python 3.13" jdkType="Python SDK" />
    <orderEntry type="sourceFolder" forTests="false" />
  </component>
</module>
03-funktion/.idea/inspectionProfiles/Project_Default.xml
New file
@@ -0,0 +1,14 @@
<component name="InspectionProjectProfileManager">
  <profile version="1.0">
    <option name="myName" value="Project Default" />
    <inspection_tool class="PyCompatibilityInspection" enabled="true" level="WARNING" enabled_by_default="true">
      <option name="ourVersions">
        <value>
          <list size="1">
            <item index="0" class="java.lang.String" itemvalue="3.13" />
          </list>
        </value>
      </option>
    </inspection_tool>
  </profile>
</component>
03-funktion/.idea/inspectionProfiles/profiles_settings.xml
New file
@@ -0,0 +1,6 @@
<component name="InspectionProjectProfileManager">
  <settings>
    <option name="USE_PROJECT_PROFILE" value="false" />
    <version value="1.0" />
  </settings>
</component>
03-funktion/.idea/misc.xml
New file
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
  <component name="Black">
    <option name="sdkName" value="Python 3.13" />
  </component>
  <component name="ProjectRootManager" version="2" project-jdk-name="Python 3.13" project-jdk-type="Python SDK" />
</project>
03-funktion/.idea/modules.xml
New file
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
  <component name="ProjectModuleManager">
    <modules>
      <module fileurl="file://$PROJECT_DIR$/.idea/03-funktion.iml" filepath="$PROJECT_DIR$/.idea/03-funktion.iml" />
    </modules>
  </component>
</project>
03-funktion/.idea/vcs.xml
New file
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
  <component name="VcsDirectoryMappings">
    <mapping directory="$PROJECT_DIR$/.." vcs="Git" />
  </component>
</project>
03-funktion/Inhalt.md
New file
@@ -0,0 +1,6 @@
# Funktionen
# Tupel
# Liste
03-funktion/gauss-ostern.py
New file
@@ -0,0 +1,48 @@
eingabe_ok = False
while not eingabe_ok:
    try:
        jahr_input = input("Geben Sie die Jahresnummer ein! ")
        x = int(jahr_input)
        eingabe_ok = True
    except:
        print("Eingabe ist keine Zahl")
# calc_oster_sunday
# argument : Jahresnummer
# rückgabe: tage im märz
def calc_oster_sunday(year: int) -> (int,int):
    a = year % 19
    k = year // 100
    m = 15 + (3*k + 3) // 4 - (8*k + 13) // 25
    d = (19*a + m) % 30
    s = 2 - (3*k + 3) // 4
    r = (d + a // 11) // 29
    og = 21 + d - r
    sz = 7 - (year + year//4 + s) % 7
    oe = 7 - (og - sz) % 7
    os = (og + oe)
    if os <= 31:
        tag = os
        monat = 3
    else:
        tag = os-31
        monat = 4
    return (tag,monat)
tag,monat = calc_oster_sunday(x)
months = (None, "Jan", "Feb", "März", "April")
print(f"Der Ostersonntag im {x} ist am {tag}ten {months[monat]}.")
canvas-bezier/.idea/canvas-bezier.iml
New file
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
  <component name="NewModuleRootManager">
    <content url="file://$MODULE_DIR$">
      <excludeFolder url="file://$MODULE_DIR$/.venv" />
    </content>
    <orderEntry type="jdk" jdkName="Python 3.10 (canvas-bezier)" jdkType="Python SDK" />
    <orderEntry type="sourceFolder" forTests="false" />
  </component>
</module>