From 69b15ce4dd27fbeae3182c2976f1e8cbb750a07b Mon Sep 17 00:00:00 2001 From: Artem-Darius Weber Date: Thu, 17 Apr 2025 13:41:15 +0300 Subject: [PATCH] =?UTF-8?q?(lab=205)=20refactor:=20=D1=83=D0=B4=D0=B0?= =?UTF-8?q?=D0=BB=D0=B8=D1=82=D1=8C=20=D0=BD=D0=B5=D0=BD=D1=83=D0=B6=D0=BD?= =?UTF-8?q?=D1=8B=D0=B5=20=D1=84=D0=B0=D0=B9=D0=BB=D1=8B=20=D0=BF=D1=80?= =?UTF-8?q?=D0=BE=D0=B5=D0=BA=D1=82=D0=B0=20=D0=B8=20=D0=BE=D0=B1=D0=BD?= =?UTF-8?q?=D0=BE=D0=B2=D0=B8=D1=82=D1=8C=20README.md?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lab 5/Dockerfile | 10 ----- lab 5/Makefile | 103 +++++++++++++++++++++++++++++++++++++++++++++ lab 5/Program.fs | 2 - lab 5/README.md | 8 ---- lab 5/lab 5.fsproj | 13 ------ 5 files changed, 103 insertions(+), 33 deletions(-) delete mode 100644 lab 5/Dockerfile create mode 100755 lab 5/Makefile delete mode 100644 lab 5/Program.fs delete mode 100644 lab 5/lab 5.fsproj diff --git a/lab 5/Dockerfile b/lab 5/Dockerfile deleted file mode 100644 index c04c4ad..0000000 --- a/lab 5/Dockerfile +++ /dev/null @@ -1,10 +0,0 @@ -FROM mcr.microsoft.com/dotnet/sdk:8.0 - -WORKDIR /app - -COPY . . - -RUN dotnet restore -RUN dotnet build -c Release - -CMD ["dotnet", "run", "--no-build", "--configuration", "Release"] \ No newline at end of file diff --git a/lab 5/Makefile b/lab 5/Makefile new file mode 100755 index 0000000..ab3a0b5 --- /dev/null +++ b/lab 5/Makefile @@ -0,0 +1,103 @@ +.PHONY: run build clean quadratic circle numbers recursion factory traverse lambda conditional examples + +# HelloWorld +run: + cd HelloWorld && dotnet run --project HelloWorld.fsproj + +build: + cd HelloWorld && dotnet build + +clean: + cd HelloWorld && dotnet clean + +all: build run + +# QuadraticEquation +quadratic: + cd QuadraticEquation && dotnet run --project QuadraticEquation.fsproj + +build-quadratic: + cd QuadraticEquation && dotnet build + +clean-quadratic: + cd QuadraticEquation && dotnet clean + +# CircleAndCylinder +circle: + cd CircleAndCylinder && dotnet run --project CircleAndCylinder.fsproj + +build-circle: + cd CircleAndCylinder && dotnet build + +clean-circle: + cd CircleAndCylinder && dotnet clean + +# NumberOperations +numbers: + cd NumberOperations && dotnet run --project NumberOperations.fsproj + +build-numbers: + cd NumberOperations && dotnet build + +clean-numbers: + cd NumberOperations && dotnet clean + +# RecursionTypes +recursion: + cd RecursionTypes && dotnet run --project RecursionTypes.fsproj + +build-recursion: + cd RecursionTypes && dotnet build + +clean-recursion: + cd RecursionTypes && dotnet clean + +# FunctionFactory +factory: + cd FunctionFactory && dotnet run --project FunctionFactory.fsproj + +build-factory: + cd FunctionFactory && dotnet build + +clean-factory: + cd FunctionFactory && dotnet clean + +# NumberTraversal +traverse: + cd NumberTraversal && dotnet run --project NumberTraversal.fsproj + +build-traverse: + cd NumberTraversal && dotnet build + +clean-traverse: + cd NumberTraversal && dotnet clean + +# LambdaTraversal +lambda: + cd LambdaTraversal && dotnet run --project LambdaTraversal.fsproj + +build-lambda: + cd LambdaTraversal && dotnet build + +clean-lambda: + cd LambdaTraversal && dotnet clean + +# ConditionalTraversal +conditional: + cd ConditionalTraversal && dotnet run --project ConditionalTraversal.fsproj + +build-conditional: + cd ConditionalTraversal && dotnet build + +clean-conditional: + cd ConditionalTraversal && dotnet clean + +# NumberExamples +examples: + cd NumberExamples && dotnet run --project NumberExamples.fsproj + +build-examples: + cd NumberExamples && dotnet build + +clean-examples: + cd NumberExamples && dotnet clean \ No newline at end of file diff --git a/lab 5/Program.fs b/lab 5/Program.fs deleted file mode 100644 index d6818ab..0000000 --- a/lab 5/Program.fs +++ /dev/null @@ -1,2 +0,0 @@ -// For more information see https://aka.ms/fsharp-console-apps -printfn "Hello from F#" diff --git a/lab 5/README.md b/lab 5/README.md index 8b3412a..11b519d 100644 --- a/lab 5/README.md +++ b/lab 5/README.md @@ -46,11 +46,3 @@ make lab5-docker-run - .NET 8.0 SDK или выше - Docker (опционально) -## Задачи лабораторной работы - -- Изучение основ функционального программирования на F# -- Применение рекурсии и хвостовой рекурсии -- Работа с функциями высшего порядка -- Использование лямбда-выражений -- Понимание каррирования и частичного применения функций -- Применение сопоставления с образцом (pattern matching) diff --git a/lab 5/lab 5.fsproj b/lab 5/lab 5.fsproj deleted file mode 100644 index 07dd8bb..0000000 --- a/lab 5/lab 5.fsproj +++ /dev/null @@ -1,13 +0,0 @@ - - - - Exe - net7.0 - lab_5 - - - - - - -