Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
206 changes: 206 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,206 @@
# Download this file using PowerShell v3 under Windows with the following comand:
# Invoke-WebRequest https://gist.githubusercontent.com/kmorcinek/2710267/raw/ -OutFile .gitignore
# or wget:
# wget --no-check-certificate http://gist.githubusercontent.com/kmorcinek/2710267/raw/.gitignore

# User-specific files
*.suo
*.user
*.sln.docstates

# Build results

[Dd]ebug/
[Rr]elease/
x64/
build/
[Bb]in/
[Oo]bj/

# NuGet Packages
*.nupkg
# The packages folder can be ignored because of Package Restore
**/packages/*
# except build/, which is used as an MSBuild target.
!**/packages/build/
# Uncomment if necessary however generally it will be regenerated when needed
#!**/packages/repositories.config

# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*

*_i.c
*_p.c
*.ilk
*.meta
*.obj
*.pch
*.pdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.tmp_proj
*.log
*.vspscc
*.vssscc
.builds
*.pidb
*.log
*.scc

# OS generated files #
.DS_Store*
Icon?

# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opensdf
*.sdf
*.cachefile

# Visual Studio profiler
*.psess
*.vsp
*.vspx

# Guidance Automation Toolkit
*.gpState

# ReSharper is a .NET coding add-in
_ReSharper*/
*.[Rr]e[Ss]harper

# TeamCity is a build add-in
_TeamCity*

# DotCover is a Code Coverage Tool
*.dotCover

# NCrunch
*.ncrunch*
.*crunch*.local.xml

# Installshield output folder
[Ee]xpress/

# DocProject is a documentation generator add-in
DocProject/buildhelp/
DocProject/Help/*.HxT
DocProject/Help/*.HxC
DocProject/Help/*.hhc
DocProject/Help/*.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html

# Click-Once directory
publish/

# Publish Web Output
*.Publish.xml

# Windows Azure Build Output
csx
*.build.csdef

# Windows Store app package directory
AppPackages/

# Others
*.Cache
ClientBin/
# [Ss]tyle[Cc]op.*
~$*
*~
*.dbmdl
*.[Pp]ublish.xml
*.pfx
*.publishsettings
modulesbin/
tempbin/

# EPiServer Site file (VPP)
AppData/

# RIA/Silverlight projects
Generated_Code/

# Backup & report files from converting an old project file to a newer
# Visual Studio version. Backup files are not needed, because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
UpgradeLog*.htm

# vim
*.txt~
*.swp
*.swo

# svn
.svn

# Remainings from resolvings conflicts in Source Control
*.orig

# SQL Server files
**/App_Data/*.mdf
**/App_Data/*.ldf
**/App_Data/*.sdf


#LightSwitch generated files
GeneratedArtifacts/
_Pvt_Extensions/
ModelManifest.xml

# =========================
# Windows detritus
# =========================

# Windows image file caches
Thumbs.db
ehthumbs.db

# Folder config file
Desktop.ini

# Recycle Bin used on file shares
$RECYCLE.BIN/

# Mac desktop service store files
.DS_Store

# SASS Compiler cache
.sass-cache

# Visual Studio 2014 CTP
**/*.sln.ide

# Visual Studio temp something
.vs/

# VS 2015+
*.vc.vc.opendb
*.vc.db

# Rider
.idea/

**/node_modules/*

# Added by Jskonst
.vscode/
Properties/

#####
# End of core ignore list, below put you custom 'per project' settings (patterns or path)
#####
20 changes: 20 additions & 0 deletions Anagrams.Tests/Anagrams.Tests.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>

<IsPackable>false</IsPackable>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.2.0" />
<PackageReference Include="xunit" Version="2.4.0" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.0" />
<PackageReference Include="coverlet.collector" Version="1.0.1" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\Anagrams\Anagrams.csproj" />
</ItemGroup>

</Project>
25 changes: 25 additions & 0 deletions Anagrams.Tests/Anagrams.Tests.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.29806.167
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Anagrams.Tests", "Anagrams.Tests.csproj", "{9A87C9FA-6174-408A-8EB0-22C581E01879}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{9A87C9FA-6174-408A-8EB0-22C581E01879}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9A87C9FA-6174-408A-8EB0-22C581E01879}.Debug|Any CPU.Build.0 = Debug|Any CPU
{9A87C9FA-6174-408A-8EB0-22C581E01879}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9A87C9FA-6174-408A-8EB0-22C581E01879}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {0D43EC57-6ED8-42CC-87DE-F9A7F0AA827B}
EndGlobalSection
EndGlobal
51 changes: 51 additions & 0 deletions Anagrams.Tests/AnagramsTests.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
using System;
using Xunit;
using Anagrams;

namespace Anagrams.Tests
{
public class AnagramsTests
{
[Fact]
public void WordsCarAndCot()
{
Assert.Equal("������� �������� 1 ����(-�)", Program.Anagrams("cat", "cot"));
}

[Fact]
public void WordsCarAndCoz()
{
Assert.Equal("������� �������� 2 ����(-�)", Program.Anagrams("cat", "coz"));
}

[Fact]
public void WordsCarsAndCat()
{
Assert.Equal("����� �� ������ ������", Program.Anagrams("cars", "cat"));
}

[Fact]
public void WordsDeerAndDeep()
{
Assert.Equal("������� �������� 1 ����(-�)", Program.Anagrams("deer", "deep"));
}

[Fact]
public void WordsMrahAndHarm()
{
Assert.Equal("������ ����� ��� �������� �����������", Program.Anagrams("mrah", "harm"));
}

[Fact]
public void WordsDarkAndYyyy()
{
Assert.Equal("������� �������� 4 ����(-�)", Program.Anagrams("dark", "yyyy"));
}

[Fact]
public void WordsAgarAndGras()
{
Assert.Equal("������� �������� 1 ����(-�)", Program.Anagrams("agar", "gras"));
}
}
}
25 changes: 25 additions & 0 deletions Anagrams.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.29806.167
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Anagrams", "Anagrams\Anagrams.csproj", "{CD48E038-A8B8-471C-822C-FDC0D53FD77F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{CD48E038-A8B8-471C-822C-FDC0D53FD77F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{CD48E038-A8B8-471C-822C-FDC0D53FD77F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{CD48E038-A8B8-471C-822C-FDC0D53FD77F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{CD48E038-A8B8-471C-822C-FDC0D53FD77F}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {9BDFA447-1C1F-4F40-AD35-227E20641E60}
EndGlobalSection
EndGlobal
8 changes: 8 additions & 0 deletions Anagrams/Anagrams.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>

</Project>
Loading