From 0b3c11690ca62921611c0f3053b2056e24e608e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=91=D1=80=D0=B8=D0=BB=D0=B8=D0=BD=20=D0=9D=D0=B8=D0=BA?= =?UTF-8?q?=D0=B8=D1=82=D0=B0?= Date: Fri, 8 May 2026 17:28:57 +0300 Subject: [PATCH] =?UTF-8?q?=D1=81=D0=BA=D0=B5=D0=BB=D0=B5=D1=82=20=D0=BF?= =?UTF-8?q?=D1=80=D0=BE=D0=B5=D0=BA=D1=82=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .idea/.gitignore | 3 +++ .idea/inspectionProfiles/profiles_settings.xml | 6 ++++++ .idea/misc.xml | 4 ++++ .idea/modules.xml | 8 ++++++++ .idea/stud203989.iml | 8 ++++++++ .idea/vcs.xml | 6 ++++++ Readme.MD | 9 +++++++++ main.py | 5 +++++ test.py | 0 9 files changed, 49 insertions(+) create mode 100644 .idea/.gitignore create mode 100644 .idea/inspectionProfiles/profiles_settings.xml create mode 100644 .idea/misc.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/stud203989.iml create mode 100644 .idea/vcs.xml create mode 100644 test.py diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..26d3352 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,3 @@ +# Default ignored files +/shelf/ +/workspace.xml diff --git a/.idea/inspectionProfiles/profiles_settings.xml b/.idea/inspectionProfiles/profiles_settings.xml new file mode 100644 index 0000000..105ce2d --- /dev/null +++ b/.idea/inspectionProfiles/profiles_settings.xml @@ -0,0 +1,6 @@ + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..dc9ea49 --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..ed7246c --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/stud203989.iml b/.idea/stud203989.iml new file mode 100644 index 0000000..d0876a7 --- /dev/null +++ b/.idea/stud203989.iml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..35eb1dd --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/Readme.MD b/Readme.MD index e69de29..51e5248 100644 --- a/Readme.MD +++ b/Readme.MD @@ -0,0 +1,9 @@ +deep_update(d: dict, path: str, value: any) -> dict + +Обновить вложенный словарь по пути, заданному через точку. Пример: "a.b.c" → d["a"]["b"]["c"] = value. + +deep_update({"a": {"b": {"c": 1}}}, "a.b.c", 42) → {"a": {"b": {"c": 42}}} +Тесты: + +assert deep_update({"a": {"b": {"c": 1}}}, "a.b.c", 42) == {"a": {"b": {"c": 42}}} +assert deep_update({}, "x.y", 5) == {"x": {"y": 5}} \ No newline at end of file diff --git a/main.py b/main.py index e69de29..3f57928 100644 --- a/main.py +++ b/main.py @@ -0,0 +1,5 @@ +def function(n): + #код программы + + +#вызов функции diff --git a/test.py b/test.py new file mode 100644 index 0000000..e69de29