Skip to content

Bor - #4

Open
Palezehvat wants to merge 11 commits into
masterfrom
Bor
Open

Bor#4
Palezehvat wants to merge 11 commits into
masterfrom
Bor

Conversation

@Palezehvat

Copy link
Copy Markdown
Owner

Bor, 2 дз

palorel and others added 10 commits March 4, 2023 16:59
…ь они идут отдельно с маленькой, при этом в каталоге отображаются с большой, а при добавлении с большой git status их не выделяет, поэтому этот комит их отдельное добавление
Другая ветка
Comment thread BWT/BWT/Program.cs Outdated
@@ -1,208 +0,0 @@
namespace Sort;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Тут тоже надо сделать так, чтобы удаления BWT не было в диффе этого пуллреквеста

Comment thread Bor/Bor/Bor.cs Outdated
Comment on lines +1 to +4
using System.ComponentModel.DataAnnotations;
using System.Text;
using System.Xml.Linq;
using static System.Net.Mime.MediaTypeNames;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Правда ли, что все using-и нужны?

Comment thread Bor/Bor/Bor.cs Outdated
namespace Bor;

// A container for storing strings, in the form of a suspended tree
public class BorClass

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

То, что он класс, и так понятно :)

Comment thread Bor/Bor/Bor.cs Outdated
// A container for storing strings, in the form of a suspended tree
public class BorClass
{
const int sizeAlphabet = 65536;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
const int sizeAlphabet = 65536;
private const int alphabetSize = 65536;

Comment thread Bor/Bor/Bor.cs Outdated
{
if (root == null)
{
throw new Exception();

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Нельзя кидать просто Exception, кидайте какие-нибудь более специфические исключения (тут, например, InvalidOperationException было бы уместно)

Comment thread Bor/BorTest/UnitTest1.cs Outdated
Assert.AreEqual(2, bor.HowManyStartsWithPrefix("end"), "Problems with the prefix test!");
}
}
} No newline at end of file

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Тестов маловато.

Comment thread Bor/BorTest/UnitTest1.cs Outdated
[Test]
public void AddTwoStringsWithTheSamePrefixBorTheNumberOfStringsWithThisPrefixIsTwo()
{
var bor = new BorClass();

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Почитайте про SetUp, чтобы не писать код инициализации трижды

@@ -3,23 +3,23 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.4.33403.182

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Внезапный стековый калькулятор в пуллреквесте про бор, его тоже надо убрать

Comment thread Bor/BorTest/UnitTest1.cs Outdated
using Microsoft.VisualBasic;
using System.Xml.Linq;

namespace BorTest

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Используйте file-scoped namespaces

Comment thread Bor/BorTest/UnitTest1.cs Outdated
@@ -0,0 +1,35 @@
using Bor;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Имя файла UnitTest1.cs не годится

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants