Datasets:

blob_id
large_stringlengths
40
40
language
large_stringclasses
1 value
repo_name
large_stringlengths
5
119
path
large_stringlengths
4
271
score
float64
2.52
4.84
int_score
int64
3
5
text
stringlengths
26
4.09M
26a1af93557abfbd3704841e2c4a7d621948fff9
C#
magerate/Geometries
/src/Cession.Geometries/Rect.cs
3.296875
3
using System; namespace Cession.Geometries { public struct Rect : IEquatable<Rect> { public static readonly Rect Empty = new Rect (0, 0, 0, 0); private double _x; private double _y; private double _width; private double _height; public Point Location { ...
1fc6a11428e278b1dce80e6ef2fe63599b8be61e
C#
agaddampalli/Algorithms
/Chapter 16 - Strings/ZigZagConversion.linq
3.046875
3
<Query Kind="Program" /> void Main() { Convert("PAYPALISHIRING", 4).Dump(); } public string Convert(string s, int numRows) { if(numRows <= 1) { return s; } var temp = new StringBuilder[numRows]; for (int i = 0; i < numRows; i++) { temp[i] = new StringBuilder(); } var currentRow = 0; var isDownward =...
2c633f83cad508db80a1c2f7df511bbd63890b5e
C#
muaddibco/Wist
/Wist.Common/Wist.Core/PerformanceCounters/IntegerCounter.cs
2.515625
3
using System.Diagnostics; namespace Wist.Core.PerformanceCounters { [CounterType(CounterType = PerformanceCounterType.NumberOfItems64)] public class IntegerCounter : PerformanceCounterBase { //public IntegerCounter(string categoryName, string counterName, string instanceName, bool readOnly = false...
815983efea3be026b9dc5dad5934bc744c8f5a82
C#
mrcretu/.NET-MVC
/DataAccess/DataAccess/Configurations/PostConfiguration.cs
2.734375
3
using System; using DataAccess.Entities; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Metadata.Builders; namespace DataAccess.Configurations { public class PostConfiguration : IEntityTypeConfiguration<Post> { public void Configure(EntityTypeBuilder<Post> builder) { ...
41129aaaef6c354da42fd919d4fbf8028b122736
C#
VeritasCarpeDiem/Double-Linked-List
/Program.cs
3.015625
3
using System; namespace Double_Linked_List { class Program { static void Main() { DoublyLinkedList<int> list = new DoublyLinkedList<int>(); list.AddFirst(1); list.AddLast(2); list.AddLast(3); list.PrintForwards(); ...
b2114a77e3c8e33a3a295509c4071bab7ec11832
C#
thankshelp/oopLab2
/lab2/Point.cs
3.046875
3
using System; using System.Collections.Generic; using System.Linq; using System.Security.Cryptography.X509Certificates; using System.Text; using System.Threading.Tasks; using System.Windows.Controls; using System.Windows.Shapes; namespace lab2 { public class Point2D { private double x, y; pub...
36beac218aa05349f2cb2cfd2e4fc39c2d8bd816
C#
hapikit/hapikit.net
/src/Hapikit.net/Parser/Context.cs
2.625
3
using System; using System.Linq; using System.Collections.Generic; namespace Hapikit { public class Context { public object Subject { get; private set; } public VocabTerm TermMap { get; private set; } public string LastProperty { get; set; } public Context(object subject, VocabT...
c738f28030cd43f34b9ce88d8b62832fac2daa39
C#
bde0x1/BoardGame
/BoardGame/InGameInformationForms/PropertyCard.cs
2.75
3
using BoardGame.Domain_Model; using System; using System.Windows.Forms; namespace BoardGame { public partial class PropertyCard : Form { public string FieldName { get; set; } public int FieldValue { get; set; } public int FieldFinishedValue { get; set; } public int FieldBuildin...
5cce7732d0f43d4a0b223fca71e2340087e733d8
C#
drowhunter/Steam-Library-Manager
/Source/Steam Library Manager/Framework/SteamIDConvert.cs
2.71875
3
using System; using System.Globalization; using System.Text.RegularExpressions; /* SteamID-NET * https://github.com/NachoReplay/SteamID-NET * GNU General Public License v3.0 * https://github.com/NachoReplay/SteamID-NET/blob/master/LICENSE */ namespace Steam_Library_Manager.Framework { /// <summary> /// A...
78b8f22f6228c5697aba1e88c38055b07de756c6
C#
fescastro/ACAI
/Acai.Api/Persistence/Contexts/AppDbContext.cs
2.625
3
using Microsoft.EntityFrameworkCore; using Acai.Api.Domain.Models; namespace Acai.Api.Persistence.Contexts { //Classe resposável por mapear os models do dominio para tabelas public class AppDbContext : DbContext { public AppDbContext(DbContextOptions<AppDbContext> options) : base(options){...
f146cc64431a5c9b9ea5a4cb4ae2550d800b01cf
C#
A-Larkins/Temple_Book_Store
/Bookstore/BookLibrary/Student.cs
3.0625
3
/* * Andrew Larkins * 09/21/20 * Student class to store info. */ using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace BookLibrary { public class Student { String id; String name; String address; Str...
fd7945b3291e6824bb66b46fe631010560af49a8
C#
Vael-hub/BlazorTutorial
/CustomerManagement.Models/ClientContact.cs
2.640625
3
using System; using System.ComponentModel.DataAnnotations; namespace BusinessManagement.Models { public class ClientContact { public int ContactId { get; set; } /// <summary> /// Prénom du client /// </summary> public string FirstName { get; set; } /// <summary>...
77373d8b0ec09dabe3b7800a386360d079533010
C#
AlexShkor/cqrs-pocker-app-example
/src/Poker/Platform/Settings/SettingsMapper.cs
3.1875
3
using System; using System.Reflection; namespace Poker.Platform.Settings { /// <summary> /// Maps application settings to your custom type or to existing instance of object /// SettingsMapper read <appSettings /> right from your *.config file /// </summary> public static class SettingsMapper {...
de6cec6fc3e6d84f98295b916882809ea3b4a995
C#
warappa/XamlCSS
/XamlCSS.XamarinForms/ComponentModel/EnumTypeConverter.cs
2.546875
3
using System; using System.Globalization; using Xamarin.Forms; namespace XamlCSS.ComponentModel { public class EnumTypeConverter<Tout> : TypeConverter { public override bool CanConvertFrom(Type sourceType) { return sourceType == typeof(string); } public override object ConvertFrom(CultureInfo culture, ob...
00eee06296918535276b1f69923bce8eb0f580db
C#
aakesh001/ongoing
/Pavani/ConsolDemo/DataTransformationEngine 20180320/DataTransformationEngine/DataStore/DataObject.cs
2.9375
3
using System; using System.Data; using System.Collections.Generic; using AppConfigurations; namespace DataStore { //Base DataObject class for the transformation engine //Contains a DataTable to hold the data //Trying out a MetaInfo to store properties of column (may not be needed) public class DataObj...
e22ab02473a27be1b4f900a507c2c9eb0703979f
C#
javierpuntonet/Alexa.NET.SkillFlow.Interpreter
/Alexa.NET.SkillFlow.Interpreter.Tests/GoToTests.cs
2.6875
3
using System; using System.Collections.Generic; using System.Text; using Alexa.NET.SkillFlow.Instructions; using Alexa.NET.SkillFlow.Interpreter; using Xunit; namespace Alexa.NET.SkillFlow.Tests { public class GoToTests { [Fact] public void CorrectlyIdentifiesText() { var i...
6000d127852d681fd50c5b697dc808dc5a945d38
C#
SureshKaushik/Algorithms
/DSAlgorithms/LinkedListOperations.cs
3.65625
4
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace DSAlgorithms { public class LinkedListOperations { public void CountLinkedList() { Node head = new Node(); Node second = new Node(); ...
237364b83c4f312a8d00b2b76943931206d445dd
C#
Kuhpik/Design-patterns
/Assets/Behavioral/Memento/RPGCharacter.cs
3.21875
3
using UnityEngine; namespace Kuhpik.DesignPatterns.Behavioral.Memento { public class RPGCharacter { public readonly string Name; //SnapshotManager class can't read private fields int _health; Vector2 _position; public RPGCharacter(string name, int health, Vector2 posit...
c94349cecf7012dad4fee9f3d09882e06e1b74bb
C#
SoftingIndustrial/OPC-Classic-SDK
/development/NET/src/client/ClientAddressSpaceElement.cs
2.640625
3
using System; using Softing.OPCToolbox.Client; using System.Runtime.InteropServices; using Softing.OPCToolbox; using Softing.OPCToolbox.OTB; namespace Softing.OPCToolbox.Client { /// <summary> /// <para>Represents an element in an OPC Server's address space.</para> /// <para> /// The elements in an OPC Server's ad...
36385f9498d23c642880ffe832a5be058f976706
C#
IlhamInsankamil/MiniProject
/BuahSayur/BuahSayur.ViewModel/DeliveryOrderHeaderViewModel.cs
2.53125
3
using System; using System.Collections.Generic; using System.ComponentModel; using System.ComponentModel.DataAnnotations; using System.Linq; using System.Text; using System.Threading.Tasks; namespace BuahSayur.ViewModel { public class DeliveryOrderHeaderViewModel { // Header public int Id { ge...
1ce03f9f0eef4cb9e0d8b129753961ca698e02a3
C#
RustamjonUsmonov/hashtable
/hashTable/hashTable/Program.cs
3.203125
3
using System; using System.Collections; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace hashTable { class ThisTable { static Hashtable userInfoHash; } class Program { static void Main(string[] args) ...
056d7fb3976abab94ee39617b4c3375433c04e0d
C#
derfy/yasb
/Yasb.Wireup/ExampleMessage.cs
2.78125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using Yasb.Common.Messaging; using System.Threading; namespace Yasb.Wireup { [Serializable] public class ExampleMessage2 : ExampleMessage { public ExampleMessage2(int number, string name) ...
1c97d5b2219ca648341fc2cab10ea07286b7ed9f
C#
alessiogiordano/Damiera
/Assets/Scripts/Classes/Player.cs
2.703125
3
using System.Collections; using System.Collections.Generic; using UnityEngine; public class Player { private int _score; public int score { get => _score; } public void AddScore(int ammount) { _score += Mathf.Abs(ammount); } public PlayerColor color { get; } public Player(PlayerColor color) { ...
4edb828fa9a9d49daea2b281821c9dae341e1c14
C#
ormikopo1988/design-patterns-csharp-dotnet
/StatePattern/ExamplesForHumans/LowerCase.cs
3
3
using System; namespace StatePattern.ExamplesForHumans { public class LowerCase : IWritingState { public void Write(string words) { Console.WriteLine(words.ToLower()); } } }
2e5cf444b3cc83f8a161381e45fcff59131c83b6
C#
selganor74/chess-sharp
/chess.core/Game/IPiece.cs
2.828125
3
using System.Collections.Generic; namespace chess.core.Game { public interface IPiece { Position Position { get; set; } Kind Kind { get; set; } Color Color { get; set; } Color OpponentsColor { get; } BoardState Board { get; set; } List<Move> ValidMoves(); ...
ba74ef1d8e0dbec218cdf1159e441d27f145236f
C#
AmitHadas/advanced2
/ImageService/ImageService/Commands/CloseGuiCommand.cs
2.671875
3
using ImageService.Commands; using ImageService.Server; using Newtonsoft.Json; using System; using System.Collections.Generic; using System.Linq; using System.Net.Sockets; using System.Text; using System.Threading.Tasks; namespace ImageService.Commands { /// <summary> /// Class CloseGuiCommand. /// </summ...
2c6d56588c4152c3819077061b7939e5e5d244ba
C#
georgelevinson/DesignPatterns
/Adapter/AdapterDI.cs
3.59375
4
using System; using System.Collections.Generic; using System.Text; namespace Adapter { public interface ICommand { void Execute(); } class SaveCommand : ICommand { public void Execute() { Console.WriteLine("Saving a file"); } } class OpenCommand ...
e85f48cffd31fecc57a27e2c9991be0db323e0ff
C#
noisynoise/Chaskis
/Chaskis/GenericIrcBot/IrcBot.cs
2.53125
3
// Copyright Seth Hendrick 2016. // Distributed under the Boost Software License, Version 1.0. // (See accompanying file ../../LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt) using System; using System.Collections.Generic; using SethCS.Basic; using SethCS.Exceptions; namespac...
0c2215ba8c046e6af6b5ad11b4c12202b95861fb
C#
thomasvt/glyphedit
/GlyphEdit/GlyphEdit.Model/Manipulation/DocumentManipulationScope.cs
2.890625
3
using System; namespace GlyphEdit.Model.Manipulation { /// <summary> /// Scope wihtin document changes (will) form a single reversable operation on the undo stack. /// </summary> public class DocumentManipulationScope { private readonly DocumentManipulator _documentManipulator; pri...
4708dcfe335887cd587f013b3a0aacfcf11eff4a
C#
Mateusz-Peplinski/Loqui
/src/design/Design.cs
3.25
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; using System.Drawing; namespace Loqui { class Design { /// <summary> /// This Function is called to invert the colour of contorls and set background i...
1944422268a1fc44bb7072015171c2b29a89b13a
C#
ZurabKV/SnakeProject
/ConsoleApp7/CreaturesFolder/Snake.cs
2.8125
3
using ConsoleApp7.CreaturesFolder; using ConsoleApp7.Entities; using ConsoleApp7.UserInterface; using System; using System.Collections.Generic; using System.Text; namespace ConsoleApp7 { class Snake : Creature, IMovable { public static int score = 0; public static int stepsMade = 0; pu...
d2488998f6219ba0a56cbe783bc3d56b48f852be
C#
mfloriani/sfas21
/Assets/Scripts/FiniteStateMachine.cs
2.625
3
using System.Collections; using System.Collections.Generic; using UnityEngine; public class FiniteStateMachine { private FSMState _currentState; public FiniteStateMachine() { } public void Start(FSMState initialState) { ChangeState(initialState); } public void Update() {...
86ecd5479de102a5945c469f39c278953045b4c7
C#
horikuss20/Apprentice
/Scripts/WaterTrigger.cs
2.75
3
using System.Collections; using System.Collections.Generic; using UnityEngine; [RequireComponent(typeof(BoxCollider))] public class WaterTrigger : MonoBehaviour { //BoxCollider for the water GameObject BoxCollider boxCollider; //CharacterController for the character CharacterController controller; ...
4c6a399ae742865fecec5dc6f2e5064dcd15f65f
C#
Merchello/Merchello
/src/Merchello.Core/Gateways/GatewayProviderBase.cs
2.59375
3
namespace Merchello.Core.Gateways { using System; using System.Collections.Generic; using Models; using Services; using Umbraco.Core; using Umbraco.Core.Cache; /// <summary> /// Defines the GatewayBase /// </summary> public abstract class GatewayProviderBase : IProvider { ...
bd7f443db2367038f904b6e8cf563769e9bb4c1f
C#
Sigf/GameJam_1-31
/src/Assets/Scripts/Controllers/enemyStats.cs
2.625
3
using UnityEngine; using System.Collections; public class enemyStats : MonoBehaviour { public Ability _ability; public float hp; public bool isInvulnerable; private SpriteRenderer _sr; private bool onHitCD; private float hitCD = 0.1f; private float hitTime = 0.0f; // Use this for initialization void Start (...
1c71bc4bf978258ad19f05535576a433008cfbea
C#
eleon88/csharp-workbook
/01Week/1.1/1.1/Program.cs
3.71875
4
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace _1._1 { class Program { static void Main(string[] args) { Console.WriteLine("Enter a number"); int number1 = int.Parse(Console.ReadLine()); ...
b7f30ffb77fee95d1192358dee15581ce3e1c7af
C#
polykhel/BizPerms
/G4.BizPermit.Dal/QuarterData.cs
2.578125
3
using G4.BizPermit.Entities; using System; using System.Collections.Generic; using System.Linq; namespace G4.BizPermit.Dal { public class QuarterData { public static List<Quarter> ListAll() { using (DB context = new DB()) { return context.Quarters.ToList...
769b8f32f1ae345d438571bc2fc47067eb84ad93
C#
sakapon/AtCoder-Contests
/CSharp/PAST/PAST202005/H.cs
3.234375
3
using System; using System.Linq; class H { static int[] Read() => Console.ReadLine().Split().Select(int.Parse).ToArray(); static void Main() { var h = Read(); int n = h[0], l = h[1]; var x = Read().ToHashSet(); var t = Read(); var dp = Enumerable.Repeat(1 << 30, l).Prepend(0).ToArray(); ...
5bb56ae6b1fabbd08427617b15679f857897a609
C#
Svengali/legba_old
/src/libs/Entity/Entity.cs
2.53125
3
using System; using System.Collections.Generic; using System.Text; using Microsoft.CodeAnalysis; using System.Diagnostics.Tracing; using lib.Net; using Validation; namespace ent { public enum EntityId : ulong { Invalid = 0, } /* public partial class ComHealth : Component { public float Health => m_health; }...
bf7c440e3b50a1205feb31a6ebb84b3b4ba4604c
C#
SJDavies2020/Review_11_12_2018
/Review_1/Form1.cs
2.71875
3
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace Review_1 { public partial class frmReview : Form { Double MyResult =...
e3fe7f489388ee03452312feb1a9959e1122a372
C#
gabsot22/beverage-collection-key
/cis237-assignment1/Program.cs
3.34375
3
// Author: David Barnes // Class: CIS 237 // Assignment: 1 using System; namespace cis237_assignment1 { class Program { static void Main(string[] args) { // Set Console Window Size Console.BufferHeight = Int16.MaxValue - 1; Console.WindowHeight = 40; ...
32c9241f67762ca2221b5d8fcffffc28566c01d7
C#
VincentH-Net/QuickCross
/Examples/CloudAuction/CloudAuction.ws/QuickCross/Templates/_APPNAME_Navigator.cs
2.53125
3
#if TEMPLATE // To add a navigator class: in the Visual Studio Package Manager Console (menu View | Other Windows), enter "Install-Mvvm". Alternatively: copy this file, then in the copy remove the enclosing #if TEMPLATE ... #endif lines and replace CloudAuction with the application name. using System; using Windows.UI...
8ceba1285e28e4c680aa2472d7d23b41090d1372
C#
retinio/eav-model
/src/EVA.Infrastructure.Data/Repositories/Repository.cs
2.734375
3
using System; using System.Threading.Tasks; using EVA.Domain.Abstractions; using EVA.Domain.Abstractions.Entity; using EVA.Infrastructure.Data.Context; using Microsoft.EntityFrameworkCore; namespace EVA.Infrastructure.Data.Repositories { public abstract class Repository<T> : IRepository<T> where T : DomainEntity,...
00979f0a8744b5dddc34b4d12ece73cd159a9bb2
C#
dmytrokulak/Epok
/sw/tests/Epok.Integration.Tests/TestHelper.cs
2.6875
3
using System; using System.Linq; namespace Epok.Integration.Tests { internal static class TestHelper { internal static T RandomEnumValue<T>(T excluding, bool includeDefault = false) where T : Enum { return Enum.GetValues(typeof(T)).OfType<T>() .First(v => (includeD...
bd5bc39b66a3df21cda27aebfe6f48ab396799d0
C#
HHUBBSolucionessss/HSFit
/GYM/Formularios/Usuarios/frmUsuarios.cs
2.515625
3
using System; using System.Data; using System.Windows.Forms; namespace GYM.Formularios { public partial class frmUsuarios : Form { string id; #region Instancia private static frmUsuarios frmInstancia; public static frmUsuarios Instancia { get { ...
c165ec189506a262bdaf2c17e7100fbc0a1f7525
C#
BorianKrustev/School
/2 Programming Fundamentals/Homework/5-Arrays/Homework/3.FoldAndSum/Program.cs
3.515625
4
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace _3.FoldAndSum { class Program { static void Main(string[] args) { int[] arr = Console.ReadLine() .Split(new char[] { ' ' }, StringSplitOptio...
0983e653abc7dc47f80fa5ce16b6c64e221bf402
C#
Kuinran/CS-inventory-project
/CS project/SQL_Instructions.cs
2.9375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Diagnostics; using MySql.Data; using MySql.Data.MySqlClient; namespace CS_project { static class SQL_Instructions { public static MySql.Data.MySqlClient.MySqlConnection SQL_...
cce9a87e7045ebb9eb37af243f6f3f63ec530e29
C#
klosejay/Gisoft.Map
/OpenSourceProjects/Gisoft.NetTopologySuite/Algorithm/RayCrossingCounter.cs
3.25
3
using Gisoft.GeoAPI.Geometries; namespace Gisoft.NetTopologySuite.Algorithm { ///<summary> /// Counts the number of segments crossed by a horizontal ray extending to the right /// from a given point, in an incremental fashion. /// <para>This can be used to determine whether a point lies in a <see cref=...
2be5ff89efecec8376bd2cab1b38ce5e21bc5fb2
C#
ufcpp/UfcppSample
/Chapters/Resource/ByRef/RefReassignment/RefReassingmentMax.cs
3.5
4
namespace ByRef.RefReassignment.RefReassingmentMax { using System; class Program { static ref int RefMaxOld(int[] array) { if (array.Length == 0) throw new InvalidOperationException(); // これまでこんな感じでインデックスで持って、 var maxIndex = 0; for (int i =...
606d1e59f24a94ea0cbf0effddb9c84c1186b582
C#
mustafasariel/EFDemoSabahSabah
/Demo5/EF/Mapping/CustomerMapping.cs
2.53125
3
using Demo5.Entity; using System; using System.Collections.Generic; using System.Data.Entity.ModelConfiguration; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Demo5.EF.Mapping { public class CustomerMapping:EntityTypeConfiguration<Customer> { public CustomerMapping() ...
7c2d4bc0dc85c3439cf4c3ff519e6f5e99128161
C#
willschipp/simple-db-rest-api-dotnet
/simple-db-rest-api/Controllers/TodoController.cs
2.75
3
using System; using System.Collections.Generic; using Microsoft.AspNetCore.Mvc; using System.Linq; using TodoApi.Models; namespace TodoApi.Controllers { [Route("api/[controller]")] public class TodoController : Controller { private readonly TodoContext _context; public TodoControll...
69a968817f4db0b72a1744f96bd003a328a9fdb8
C#
baba-s/UniSequenceTask
/Scripts/ISequenceTask.cs
3.296875
3
using System; using System.Collections; namespace Kogane { /// <summary> /// タスクのインターフェイス /// </summary> public interface ISequenceTask : IEnumerable { /// <summary> /// タスクを追加します /// </summary> void Add( string text, Action<Action> task ); /// <summary> /// タスクを実行します /// </summary> void Play(...
8959cc9a9474a8f43da0ef3acdebea01a00bf397
C#
AllFi/Assistant
/Plugins/MusicPlugin/MusicProviders/MusicProvider.cs
2.625
3
 namespace MusicPlugin.MusicProviders { public abstract class MusicProvider { public abstract string Name { get; } public abstract void TurnOn( string musicRequest ); public abstract void TurnOff(); public abstract void Play(); public abstract void Pause(); publi...
0d9755e80cebcceb9202c73f084474fd98e3fce8
C#
Sunkatta/My-HW-Projects-At-Uni
/I-st Course/STD1A-LusianManolov-1701681009-H8/AverageNumber/Program.cs
3.9375
4
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace AverageNumber { class Program { static void Main(string[] args) { int number; int sum = 0; int br = 0; do {...
2f3e88c7cd6b766e14b4e3477d88a90681be39a8
C#
biagianina/JSONClasses
/Range.Tests/OneOrMoreTests.cs
3.015625
3
using System; using Xunit; namespace Classes.Tests { public class OneOrMoreTests { [Fact] public void ReturnsFalseAndEmptyForEmptyString() { var a = new OneOrMore( new Range('0', '9')); Assert.False(a.Match("").Success()); Assert.Equa...
4e758f7e98ff664939d7c8597564e3850f30ecc9
C#
libla/Mapping
/Mapping/MySQL.cs
2.546875
3
using System; using System.Data; using System.Data.Common; using System.Text; using System.Threading; using System.Threading.Tasks; using MySql.Data.MySqlClient; namespace Mapping { public class MySQL : DataSource { private static int total = 0; private readonly string host; private readonly i...
22056953a88f24a6a93f41ba7373e42e8af3185b
C#
JustCallMeAD/CoreSystem
/CoreSystem/Sys/DateTimeExtensions.cs
3.65625
4
using System; public static class DateTimeExtensions { /// <summary> /// Converts a DateTime to the last day of it's financial year. /// </summary> /// <param name="dt"></param> /// <returns></returns> public static DateTime ToLastDayOfFinancialYear(this DateTime dt) { return new D...
e5744d727689396cf88283fa97fc458895348948
C#
vassildinev/CSharp-Part-2
/09.CSharp-2-Exam-Preparation/OTHER_EXAM_PROBLEMS/KukataIsDancing/KukataIsDancing/KukataIsDancing.cs
3.796875
4
using System; class KukataIsDancing { const int size = 3; static void Main() { //INPUT, SOLUTION & OUTPUT int numberOfDances = int.Parse(Console.ReadLine()); int[,] matrix = new int[size, size]; FillMatrix(matrix); for (int i = 0; i < numberOfDances; i++) {...
f9c87c152cb94d97f73f8529dfa8a499bdc61e1a
C#
GalinaSazonova/2semester
/05.03.14/1/ParseTree/Operand.cs
3.03125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ParseTree { /// <summary> /// Class for operands. /// </summary> public class Operand : ParseTreeNode { public Operand(string expr) { this.Value...
6b5904d114069ea7ca766a7a7f7c849d1ce778e1
C#
Thebirate/uplink.net
/uplink.NET/uplink.NET/Services/UploadQueueService.cs
2.640625
3
using SQLite; using SQLitePCL; using System; using System.Collections.Generic; using System.IO; using System.Text; using System.Threading; using System.Threading.Tasks; using uplink.NET.Interfaces; using uplink.NET.Models; namespace uplink.NET.Services { public class UploadQueueService : IUploadQueueService {...
7d86ee806f604e5e388bf56e10620dda5662b562
C#
alittlesail/VSIX-ALittleScript
/Guess/ALittleScriptGuessClass.cs
2.59375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ALittle { public class ALittleScriptGuessClass : ALittleScriptGuess { // 命名域和类名 public string namespace_name = ""; public string class_name = ""; // 类本...
f28381784c96f3fec04b9bd3c66a9bc6e42f367f
C#
Titaniumstein/PodiatryApplication
/View/Events/EventListener.cs
2.515625
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace View.Events { public class EventListener<TMessage> : IEventListener<TMessage> { private readonly EventOrchestrator<TMessage> orchestrator; public EventListener(EventOr...
82e91988f0e4f351736f141c68a24bda3db43365
C#
trixtur/CsBot
/src/CsBot/Command/RssFeedCommand.cs
2.796875
3
using System; using System.Linq; using System.Net; using System.ServiceModel.Syndication; using System.Xml; namespace CsBot.Command { class RssFeedCommand { readonly CommandHandler handler; SyndicationFeed feed; int count; Users Users { get => handler.Users; } string Addres...
f73414adf90cdfe8a55d06210940c404d6764d5a
C#
Campbell20/GameHog
/GameHog/Models/Store.cs
2.578125
3
using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using System.Linq; using System.Web; namespace GameHog.Models { public class Store { //Store's unique identification number in the table public int I...
d1c1d68c42cf9b2ce59e8af7c5559338865e0dca
C#
planettelex/Bloom
/Shared/Bloom.Data/Repositories/ArtistRepository.cs
2.90625
3
using System; using System.Collections.Generic; using System.Data.Linq; using System.Linq; using Bloom.Data.Interfaces; using Bloom.Domain.Models; namespace Bloom.Data.Repositories { /// <summary> /// Access methods for artist data. /// </summary> public class ArtistRepository : IArtistRepository ...
887df78787e259305b9609b4d895e549b2292148
C#
radtek/vprint
/PTFReports/PTFReportsLib/Extentions/IListEx.cs
2.65625
3
/*************************************************** // Copyright (c) Premium Tax Free 2012 /***************************************************/ using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; namespace PTF.Reports { public static class IListEx ...
7c4025502f83871df6c4722d95143c7dd2c0d72e
C#
mstarski/file-manager
/FileManager/DataModels/MyDirectory.cs
3.390625
3
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows; /// <summary> /// MyDirectory Class represents system directories /// </summary> namespace FileManager.DataModels { public class MyDirectory : IDiscElement ...
179d620eadc162762ad31854059c9eb677019854
C#
scbj/musixx
/Musixx.Shared/ApplicationSettingsHelper.cs
2.65625
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using Windows.Storage; namespace Musixx.Shared { public static class ApplicationSettingsHelper { public static object ReadResetSettingsValue(string key) { object valu...
5839fdb821c85c6b623f937afc16eb707e3a5da2
C#
DanteDercksen/GADE6112_POE_19014267_Task1
/Tile.cs
2.828125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace GADE6112_POE_19014267 { abstract class Tile { public enum TileType { HERO, ENEMY, GOBLIN, WEAPON}; protected int x; protected int y; public int X ...
f55e10af397ad23246018d02b237a7462c449487
C#
saglag/LJPcalc
/src/LJPmath/Constants.cs
2.640625
3
using System; using System.Collections.Generic; using System.Text; namespace LJPmath { public static class Constants { // Boltzmann constant = 1.38064852e-23 (m^2 * kg) / (s^2 * K) public const double zeroCinK = 273.15; public const double boltzmann = 1.38064852e-23; // Elementary charge = 1.602176634e-19 ...
75ed631974e349f3aee55b7fe6433ba1c2f1da52
C#
MartinNikolovMarinov/CSharp_DSA
/SoftUni/DataStructures/04.Trees/Homework/TraverseAndSaveDirectory/MyFile.cs
2.890625
3
namespace TraverseAndSaveDirectory { public class MyFile { public int Size { get; set; } public string Name { get; set; } public MyFile(string name, int size) { this.Name = name; this.Size = size; } } }
900a1a6f87f6d2b2e7af918c5daa91e07c1a323d
C#
sedc-codecademy/sedc6-csharp
/src/Advanced05/Advanced05/Extensions.cs
3.28125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Advanced05 { static class Extensions { public static void PrintCollection<T>(this IEnumerable<T> collection) { foreach (var item in collection) ...
698cabfccc23d4c5a1bd84ab39bb089311a7cc16
C#
peachpiecompiler/peachpie
/src/Peachpie.Runtime/Collections/ValueList`1.cs
3.109375
3
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.Text; namespace Pchp.Core.Collections { /// <summary> /// <see cref="IList{T}"/> implementation as a value type. /// </summary> [DebuggerDisplay("{typeof(T).FullName,nq}[{_count}]")] pu...
7b1069526efaa53cd2edd2d138eedd7584a59b6d
C#
fjesualdo/Testes
/Console/models/NewStudent.cs
3.078125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Console { public class ListNewStudent : List<NewStudentt> { public ListNewStudent() { } // Create a data source by using a collection initiali...
88901f137866fd99bccda91cfd473bd0c974e6ba
C#
BorislavD/Arrays-and-Lists-CSharp
/CamelsBack.cs
3.609375
4
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace CamelsBack { class CamelsBack { static void Main(string[] args) { List<int> list = Console.ReadLine().Split().Select(int.Parse).ToList(); ...
d882de15cb04f4a650fdec6cdb47f6eaa702fbc4
C#
ajabotomey/DialoguePrototype
/Assets/DialogueSystem/Scripts/ParseEmojis.cs
3.109375
3
using System.Collections; using System.Collections.Generic; using UnityEngine; using System.Text; public static class ParseEmojis { public static string Parse(string text) { char[] separators = { '(', ')' }; // Go through and detect parenthesis and make substrings string[] textChunks ...
b9a8bc793bba39955173a8107f5faaa7120c8f69
C#
AngelDimitrov52/Software-University
/2.C# Fundamentals/Homeworks and labs/09.RegularExtresion/RegularExpresionExe/05.NetherRealms/Program.cs
3.484375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; namespace _05.NetherRealms { class Program { static void Main(string[] args) { string[] demons = Console.ReadLine() .Split(new char[] { ' ', ',' }, StringSplitOp...
ca7329b20274c5732535acacd3afad8e2f265f71
C#
lvetskov/Telerik_Academy_Homework_Projects
/OOP/exam/Furniture/FurnitureManufacturer/Models/Table.cs
3.453125
3
namespace FurnitureManufacturer.Models { using FurnitureManufacturer.Interfaces; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; public class Table : Furniture, ITable { private decimal length; private ...
ccdd564515fe9541a05bfa722806d68bb75386c3
C#
eshohag/ASP.Net-MVC5-Apps
/UniversityRegistrationProcess/UniversityRegistrationProcess/Gateway/SemesterGateway.cs
2.890625
3
using System; using System.Collections.Generic; using System.Data.SqlClient; using System.Linq; using System.Web; using UniversityRegistrationProcess.Models; namespace UniversityRegistrationProcess.Gateway { public class SemesterGateway:CommonGateway { public List<Semester> GetAllSemesters() {...
275b39905479e6acce108b38ff1191dc5c866e08
C#
shendongnian/download4
/first_version_download2/407875-35614865-111690470-2.cs
2.859375
3
string status = string.Empty; Thread thread = new System.Threading.Thread(() => { status = Download(downloadKit, patchTitle); }); thread.Start(); thread.Join(); //no point in looping here, if the thread finished, it has already assigned the //value it is going to assign to t...
79e18a2a3fcc00799689c82c74541de059b15106
C#
ThomasH94/BreakoutMania
/Assets/_Project/Scripts/Scoring Systems/LivesManager.cs
2.625
3
using BrickBreak.EventManagement; using BrickBreak.GameManagement; using BrickBreak.Singletons; using TMPro; using UnityEngine; namespace BrickBreak.GameManagement { public class LivesManager : Singleton<LivesManager> { [SerializeField] private TextMeshProUGUI livesText = null; [SerializeFiel...
7d9555e6a01cf80883441bb203064be908dc39d4
C#
DamirAinullin/RedisSessionProvider
/RedisSessionProviderUnitTests/RedisSessionStateItemCollectionTests/SingleThreadedTests.cs
2.515625
3
namespace RedisSessionProviderUnitTests.RedisSessionStateItemCollectionTests { using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using NUnit.Framework; using Moq; using RedisSessionProvider; using RedisSessionProvide...
3f9843deaf9ccc828764db85cda9714a65086003
C#
BastienPerdriau/HelpFileMarkdownBuilder
/Sources/HelpFileMarkdownBuilder/Language.cs
3.125
3
using HelpFileMarkdownBuilder.Base; using HelpFileMarkdownBuilder.CSharp.Builder; using System; using System.Linq; namespace HelpFileMarkdownBuilder { /// <summary> /// Languages to build help files /// </summary> public abstract class Language : Enumeration { /// <summary> /// C# ...
254823e2a4b82f1e73ca6f3903846ac35e90b3d3
C#
level2player/LiteCache
/src/LiteCache/LiteCache.cs
2.6875
3
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Threading; using System.Threading.Tasks; using System.Timers; namespace Lsy.core.LiteCache { public class LiteCache<T> { Dictionary<string, T> globalDictionary = new Dictionary<string, T> (); ...
95b1ac60bf35cf4f3fa56301e5bbdf575ef5b4ee
C#
bubdm/Pyro
/Library/Language/RhoLang/Parser/RhoAstFactory.cs
2.625
3
namespace Pyro.RhoLang.Parser { using System.Collections.Generic; using Language; using Lexer; /// <inheritdoc /> /// <summary> /// Make RhoAstNodes with various arguments. /// Required because C# doesn't allow template types to /// take parameters for constructors. /// Also, becau...
9763a05dad009022dadd454d71165ae9f1752822
C#
benny502/2OG
/2og_logic_pack/2og_logic_pack/Logic.cs
2.9375
3
using System; using System.Collections.Generic; using System.IO; using System.Text; namespace _2og_logic_pack { class Logic { //文本数 private int _count; public int count { get { return _count; } } private int _txtEntry; public int txtEntry { get { return _txtEntry;} } ...
65e6a0bd94a3e0ec75277e5b65cdfbe323bdb574
C#
4373/timesheet
/TimeSheet/UsrUI/MyTextBox.cs
2.796875
3
using System; using System.Collections.Generic; using System.ComponentModel; using System.Drawing; using System.Data; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace TimeSheet.UsrUI { public partial class MyTextBox : UserControl { //[Descriptio...
43ef520b0e49059e24139309d45f936a9ef5058a
C#
shendongnian/download4
/code9/1520511-47837289-173829147-1.cs
4.03125
4
class Program { static void Main(String[] args) { // By using extension methods if ( "Hello world".ContainsAll(StringComparison.CurrentCultureIgnoreCase, "Hello", "world") ) Console.WriteLine("Found everything by using an extension method!"); else...
069f72c40a7eccecd2c20f1e9398ef5844f5394d
C#
datvm/Training-WebMonitor
/WebMonitor.ServiceCore/WebMonitorService.cs
2.515625
3
using System; using System.Diagnostics; using System.Threading; using System.Threading.Tasks; using WebMonitor.ServiceCore.Services; namespace WebMonitor.ServiceCore { public class WebMonitorService : IDisposable { private CancellationTokenSource cts; public void Start() { ...
63bc1e8f0d0d1164d8368105e45782c154d099a6
C#
WokeGames/transcendance
/Scripts/CSharp/Biomes.cs
2.53125
3
using Godot; using Godot.Collections; using System.Collections.Generic; using System; using System.Linq; using System.Text; using System.Threading.Tasks; using Array = Godot.Collections.Array; namespace RogueCity.Scripts.CSharp { public class Biomes : Node2D { public GroundTileScript[] tiles; [Export] public i...
e1846c77c56950c56be2a6b13a617d39b628d8d1
C#
thinhpham/thp.aws.library
/Thp.Aws.Utility/CryptographyUtility.cs
3.203125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Security.Cryptography; using System.IO; namespace Thp.Har.Utility { public static class CryptographyUtility { #region Hash public static string ComputeHash(string value) { return ComputeH...
6bd17b47144f412ec7ada1f25111a177c0453678
C#
DomideAdrian/Tema_Restaurant
/ClientApp/Restaurant/WriteMessage.cs
2.75
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Restaurant { class WriteMessage { public string WeldPhrase(string flag, List<string> weldWord) { string message = flag + ";"; foreach(var elemen...
8a140afad377ae8ab16ce03168fad73454f2a1af
C#
linekerpablo/TesteWTime
/TesteWTime.Infra/Repositories/UrlsRepository.cs
2.53125
3
using TesteWTime.Domain.Entities; using System.Collections.Generic; using TesteWTime.Domain.Interfaces; using System.Linq; using System.Data.SqlClient; using System.Text; using Newtonsoft.Json.Linq; using System; using Newtonsoft.Json; namespace TesteWTime.Infra.Repositories { public class UrlsRepository : Reposit...
a395498409f8428909450a0b8eeee44e498570e0
C#
shendongnian/download4
/first_version_download2/80354-5198495-11081426-2.cs
3.09375
3
internal class ParseXML { public static xsdClass ToClass<xsdClass>(XElement ResponseXML) { return deserialize<xsdClass>(ResponseXML.ToString(SaveOptions.DisableFormatting)); } private static result deserialize<result>(string XML) { using (TextRea...
43ea7922a07a88699e312c1364dbff0e18305683
C#
audinowho/RogueElements
/RogueElements/MapGen/Rooms/RoomGenBump.cs
2.5625
3
// <copyright file="RoomGenBump.cs" company="Audino"> // Copyright (c) Audino // Licensed under the MIT license. See LICENSE file in the project root for full license information. // </copyright> using System; using System.Collections.Generic; namespace RogueElements { /// <summary> /// Generates a rectangul...
d8a6bc775b9de868a31793f6d234e94cbd6f5a27
C#
MichalTichy/aGrader
/CAC/TestResult.cs
2.671875
3
#region using System; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Globalization; using System.Linq; using aGrader.Mathematic; using aGrader.Properties; #endregion namespace aGrader { public class TestResultArgs : EventArgs { public TestResult Result { get; se...
2db595ad792919e4e3c1864a2a57b0b96fd38562
C#
TS-Patterns/identify-valid-objects-and-design-low-level-design-sundeep-a-s
/Assignment-Day 4/VisitorPattern/VisitorPattern/DocumentConverters/PdfConverter.cs
2.515625
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using VisitorPattern.interfaces; using VisitorPattern.Models; namespace VisitorPattern.DocumentConverters { public class PdfConverter:IDocumentConverter { public void Convert(Paragraph p...
e599b8e5208246ef4fe7a02a8b020eca3661be3d
C#
azniv/Snakes
/WindowsFormsApp13/Snake.cs
3.421875
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Drawing; using System.Windows.Forms; namespace WindowsFormsApp13 { public class Snake { string direction = "right"; string nextDirection = "right"; delegate s...
8dbe3d1d0fef06324ba30b97544d0deae69b94ac
C#
shendongnian/download4
/code4/657767-15680626-38208135-2.cs
2.75
3
List<Item> items = new List<Item>(); items.Add(new Item() { Id = 1, ParentId = 0 }); items.Add(new Item() { Id = 2, ParentId = 0 }); items.Add(new Item() { Id = 3, ParentId = 0 }); items.Add(new Item() { Id = 4, ParentId = 1 }); items.Add(new Item() { Id = 5, ParentId = 1 }); items.Add(new I...
aaa5c0c1d12c2ec94d7c26926bc844e94f3b85ac
C#
sls1j/ExploreItGame
/ExploreItGame/Program.cs
2.703125
3
using System; using ExploreItGame.Nouns; using ExploreItGame.Verbs; using SDL2; namespace Hello { class Program { static void Main(string[] args) { if (SDL.SDL_Init(SDL.SDL_INIT_VIDEO) < 0) { Console.WriteLine("Unable to initialize SDL. Error: {0}", SDL.SDL_GetError()); } e...