Skip to content

Commit

Permalink
Merge pull request #5 from lukasz-stepien-dev/11.09.22-Exercises
Browse files Browse the repository at this point in the history
11.09.22 exercises
  • Loading branch information
lukasz-stepien-dev authored Feb 1, 2023
2 parents 333856c + ca562c2 commit 347df5e
Show file tree
Hide file tree
Showing 27 changed files with 257 additions and 1 deletion.
10 changes: 9 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@

09.11.22-Exercises/.vs/09.11.22-Exercises/FileContentIndex/e0fa99c5-4482-469d-87b9-04b2f62c0391.vsidx
09.11.22-Exercises/.vs/09.11.22-Exercises/FileContentIndex/f09e208a-03ad-4feb-8f6c-96f4f01bb22b.vsidx
09.11.22-Exercises/.vs/09.11.22-Exercises/v17/Browse.VC.db
09.11.22-Exercises/.vs/09.11.22-Exercises/v17/Browse.VC.db-shm
09.11.22-Exercises/.vs/09.11.22-Exercises/v17/Browse.VC.db-wal
09.11.22-Exercises/.vs/09.11.22-Exercises/v17/Browse.VC.opendb
09.11.22-Exercises/.vs/09.11.22-Exercises/FileContentIndex/e0fa99c5-4482-469d-87b9-04b2f62c0391.vsidx
09.11.22-Exercises/.vs/09.11.22-Exercises/v17/Browse.VC.db
28.09.22 Pointers/.vs/28.09.22 Pointers/FileContentIndex/62e9f42d-27ae-47d8-ba15-056e28c3754d.vsidx
28.09.22 Pointers/.vs/28.09.22 Pointers/FileContentIndex/read.lock
28.09.22 Pointers/.vs/28.09.22 Pointers/v17/Browse.VC.db
Expand All @@ -7,4 +15,4 @@
28.09.22 Pointers/.vs/28.09.22 Pointers/v17/Browse.VC.opendb
28.09.22 Pointers/.vs/28.09.22 Pointers/v17/ipch/AutoPCH/d3499647f6c32424/ARRAYS.ipch
28.09.22 Pointers/.vs/28.09.22 Pointers/FileContentIndex/28907f32-6c92-481d-9a58-50e802e3a656.vsidx
28.09.22 Pointers/.vs/28.09.22 Pointers/v17/Browse.VC.db
28.09.22 Pointers/.vs/28.09.22 Pointers/v17/Browse.VC.db
Binary file not shown.
Empty file.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
31 changes: 31 additions & 0 deletions 09.11.22-Exercises/09.11.22-Exercises.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.3.32825.248
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "09.11.22-Exercises", "09.11.22-Exercises\09.11.22-Exercises.vcxproj", "{60CE0BA0-269B-4521-9A32-B5E025AFB316}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{60CE0BA0-269B-4521-9A32-B5E025AFB316}.Debug|x64.ActiveCfg = Debug|x64
{60CE0BA0-269B-4521-9A32-B5E025AFB316}.Debug|x64.Build.0 = Debug|x64
{60CE0BA0-269B-4521-9A32-B5E025AFB316}.Debug|x86.ActiveCfg = Debug|Win32
{60CE0BA0-269B-4521-9A32-B5E025AFB316}.Debug|x86.Build.0 = Debug|Win32
{60CE0BA0-269B-4521-9A32-B5E025AFB316}.Release|x64.ActiveCfg = Release|x64
{60CE0BA0-269B-4521-9A32-B5E025AFB316}.Release|x64.Build.0 = Release|x64
{60CE0BA0-269B-4521-9A32-B5E025AFB316}.Release|x86.ActiveCfg = Release|Win32
{60CE0BA0-269B-4521-9A32-B5E025AFB316}.Release|x86.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {C16674E0-CB09-4F17-A06A-4E5FA153D0F0}
EndGlobalSection
EndGlobal
40 changes: 40 additions & 0 deletions 09.11.22-Exercises/09.11.22-Exercises/09.11.22-Exercises.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
#include <iostream>
#include <cmath>

// Łukasz Stępień

using namespace std;



//
float ex1(int brutto, float tax)
{
float taxPct = 1;
taxPct -= tax / 100;
return brutto * taxPct;
}

int main()
{
int brutto = 0, tax = 0;
cout << "Podaj kwote brutto: ";
cin >> brutto;
cout << "Podaj podatek: ";
cin >> tax;
cout << "Cena netto: " << ex1(brutto, tax) << endl;

string products[] = { "Ogorki", "Pomidory", "Ziemniaki", "Jablka" };
int idProduct = 0;
cout << "Podaj numer produkty, ktory chcesz wyświetlis" << endl;
cin >> idProduct;
idProduct--;
while (idProduct > 3 || idProduct < 0)
{
cout << "Podaj poprawna wartosc: ";
cin >> idProduct;
idProduct--;
}
cout << "Wybrany produkt: " << products[idProduct];
}

135 changes: 135 additions & 0 deletions 09.11.22-Exercises/09.11.22-Exercises/09.11.22-Exercises.vcxproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,135 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>16.0</VCProjectVersion>
<Keyword>Win32Proj</Keyword>
<ProjectGuid>{60ce0ba0-269b-4521-9a32-b5e025afb316}</ProjectGuid>
<RootNamespace>My091122Exercises</RootNamespace>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Console</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="09.11.22-Exercises.cpp" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Pliki źródłowe">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Pliki nagłówkowe">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd</Extensions>
</Filter>
<Filter Include="Pliki zasobów">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="09.11.22-Exercises.cpp">
<Filter>Pliki źródłowe</Filter>
</ClCompile>
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup />
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<Project>
<ProjectOutputs>
<ProjectOutput>
<FullPath>C:\Users\ŁukaszStępień2021_20\OneDrive - Zespół Szkół Politechnicznych\szkolne\Przedmioty Szkolne GitHub\PPAD\09.11.22-Exercises\x64\Debug\09.11.22-Exercises.exe</FullPath>
</ProjectOutput>
</ProjectOutputs>
<ContentFiles />
<SatelliteDlls />
<NonRecipeFileRefs />
</Project>
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
 09.11.22-Exercises.cpp
C:\Users\ŁukaszStępień2021_20\OneDrive - Zespół Szkół Politechnicznych\szkolne\Przedmioty Szkolne GitHub\PPAD\09.11.22-Exercises\09.11.22-Exercises\09.11.22-Exercises.cpp(25,43): warning C4244: "argument": konwersja z "int" do "float", możliwa utrata danych
09.11.22-Exercises.vcxproj -> C:\Users\ŁukaszStępień2021_20\OneDrive - Zespół Szkół Politechnicznych\szkolne\Przedmioty Szkolne GitHub\PPAD\09.11.22-Exercises\x64\Debug\09.11.22-Exercises.exe
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
PlatformToolSet=v143:VCToolArchitecture=Native64Bit:VCToolsVersion=14.33.31629:TargetPlatformVersion=10.0.19041.0:
Debug|x64|C:\Users\ŁukaszStępień2021_20\OneDrive - Zespół Szkół Politechnicznych\szkolne\Przedmioty Szkolne GitHub\PPAD\09.11.22-Exercises\|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 comments on commit 347df5e

Please sign in to comment.