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
5aedf921095245b2a39f507cf29010840ebb0e39
C#
AlexanderMeshchaninov/MetricsManager_Project
/MetricsManager_Project/MetricsAgent/Controllers/RamMetricsController.cs
2.734375
3
using Microsoft.AspNetCore.Mvc; using System.Collections.Generic; using Microsoft.Extensions.Logging; using MetricsAgent.Requests; using MetricsAgent.Responses; using MetricsAgent.DAL; using AutoMapper; namespace MetricsAgent.Controllers { [Route("api/metrics/agent/ram")] [ApiController] publi...
82843dd274ae8e0b84167e657228d4eeedb9a352
C#
mohitt/leetcode
/4.median-of-two-sorted-arrays.cs
3.421875
3
/* * @lc app=leetcode id=4 lang=csharp * * [4] Median of Two Sorted Arrays * * https://leetcode.com/problems/median-of-two-sorted-arrays/description/ * * algorithms * Hard (25.07%) * Total Accepted: 366.4K * Total Submissions: 1.5M * Testcase Example: '[1,3]\n[2]' * * There are two sorted arrays nums1 ...
b2e7559c385758f581a7d01cbb8eea4e3ad27649
C#
JasonCrease/Twef
/pets/PetInfoGrabber/Program.cs
3
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.IO; using System.Text.RegularExpressions; namespace PetInfoGrabber { class Program { static void Main(string[] args) { string notFoundBreedsFile = ".\\.....
b9294ee5d0d97bdbe5dbf3e5b07ee75ed8e476b8
C#
shendongnian/download4
/code7/1190985-31627394-95952530-6.cs
2.734375
3
private void backgroundWorker1_DoWork(object sender, DoWorkEventArgs e) { while(!this.IsDisposed) { // if we have animations while(Animations.List.Count > 0) { // iterate over all of them fore...
e90564f2cbfdc76773aa8ffe903191b3fc876b4a
C#
Syncaidius/MoltenEngine
/Molten.Font/MacStyleFlags.cs
2.609375
3
namespace Molten.Font { [Flags] /// <summary>A font's mac-style.</summary> public enum MacStyleFlags : ushort { None = 0, Bold = 1, Italic = 2, Underline = 4, Outline = 8, Shadow = 16, Condensed = 32, Extended = 64, Reserve...
48fca76dfc65a137a582a59017962ed6a1231539
C#
AljosaDmitrovic/Warehouse
/WarehouseApp/Forms/ProductCard.cs
2.609375
3
using BusinessLayer; using DataLayer.Models; 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 WarehouseApp.Forms { public partial class Pro...
d4828fd02ae476ddbd394edf79ebc21cf74b7ad9
C#
YiZhang-Paul/Daily_Programmer
/challenge_341/intermediate/incomingAircraft/incomingAircraft/EquationFinder.cs
3.3125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace incomingAircraft { class EquationFinder { public Line GetEquation(string lineString) { var numbers = Utility.ToNumbers(lineString); //check for degree 0, ...
01cc90e59dd7126390b048fddb6b04efe8bdd42d
C#
Flotto85/ExplorIO
/ExplorIO.Data/Project.cs
2.796875
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.ComponentModel; using System.Xml.Serialization; using System.IO; using System.Runtime.Serialization; using System.Xml; namespace ExplorIO.Data { [DataContract] public class Project : INotifyPropertyChanged {...
48364ba540ae26ec57436d8c22065ede01665e7f
C#
everyday-solution/ESolutions.LifeLog
/Models/User.cs
2.96875
3
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Security.Cryptography; using System.Text; using System.IO; namespace ESolutions.LifeLog.Models { public partial class User { //Properties #region Gender /// <summary> /// Gets or sets the gender. /// </summar...
4012b095e78b00ec39ebad2ecef55a757e3e0ec2
C#
zh672903/NetFreeSwitch.Framework
/NetFreeSwitch.Framework/FreeSwitch/Commands/SayCommand.cs
3
3
/* Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this f...
a8f3f609834ed1b1349505bc481d7519008b4bbb
C#
dnywu/dokuku.tools
/POS/Packages/src/dokuku.tools.pos.packages.console/Program.cs
2.625
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using dokuku.tools.pos.packages.repositories; using NServiceBus; namespace dokuku.tools.pos.packages.console { class Program { static IPOSLogRepository posLogRepository; static RecalculateService ...
95a83f6f116ac58cc761427bc435d95f8196ebeb
C#
mayongpv/FlappyBird_ResetByYJ
/Assets/Script/Common/GameManager.cs
2.546875
3
using UnityEngine; using UnityEngine.SceneManagement; using UnityEngine.UI; using System; public class GameManager : MonoBehaviour { static public GameManager instance; public GameObject gameOverUI; public float scrollSpeedXMultiply = 1; public Text scoreUI; Text highScoreText; int highScore...
33954cfe7574237a8d19dd54af32b71e423e608d
C#
opserver/Opserver
/src/Opserver.Web/Security/SecurityProvider.cs
2.515625
3
using System; using System.Collections.Concurrent; using System.Collections.Generic; using System.Linq; using System.Net; using System.Security.Claims; using Microsoft.Extensions.Primitives; using Opserver.Data; using Opserver.Models; namespace Opserver.Security { public abstract class SecurityProvider { ...
d115137f93fac606a0d0b6537d4082636bf9ae4c
C#
rds1983/EffectFarm
/src/efscriptgen/Program.cs
2.671875
3
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Reflection; using System.Text; using System.Xml.Linq; namespace EffectFarm { enum OutputType { MGDX11, MGOGL, FNA } class Program { public static string Version { get { var assembly = typeof(Prog...
aa0373adeb64eaa012631d5ac36df951b6a64bed
C#
NgocSon288/Mobile---WebAPI
/ElectronicShopAPI/ElectronicShopAPI/Models/DAO/AdvertisementDAO.cs
2.53125
3
using ElectronicShopAPI.Models.DTO; using ElectronicShopAPI.Models.EF; using System; using System.Collections.Generic; using System.Data.Entity; using System.Linq; using System.Threading.Tasks; using System.Web; namespace ElectronicShopAPI.Models.DAO { public class AdvertisementDAO { private static Ad...
491d65f5763c5d3e63963d75984a822a9d7556dc
C#
Maxyee/HackerRankSolve
/CSharpChallenges/ArrayDs/Program.cs
3.265625
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ArrayDs { class Program { static void Main(String[] args) { int n = Convert.ToInt32(Console.ReadLine()); string[] arr_temp = Console.ReadLine()....
f7a7c91003f6d2ac6828909421b266d75c01597b
C#
KingOfSinghs/SpaceInvaders
/Final Program CPSC2/Space_Invaders_WINFORM/Space_Invaders_WINFORM/Form3.cs
2.828125
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 Space_Invaders_WINFORM { public partial class Form3 : Form { str...
b4b66b8c50a36071ac0341be7dee9d1485c91bb7
C#
jdbalantar/holbertonschool-csharp-1
/0x06-csharp-classes/1-enemy/1-enemy.cs
3.0625
3
using System; namespace Enemies { /// <summary> Class Zombie </summary> public class Zombie { /// <summary> should be an int and have no value </summary> public int health; /// <summary> Method Constructor that inicialize health value</summary> public Zombie() ...
777dcb7b52f83d66cafaf564d5df91248a75dcb8
C#
filipetoscano/Platinum
/src/Platinum.Core/Globalization/CultureFactory.cs
2.65625
3
using System; using System.Collections.Generic; using System.Globalization; using System.Linq; namespace Platinum.Globalization { /// <summary /> public static class CultureFactory { private static Dictionary<string, CultureInfo> _cultures = new Dictionary<string, CultureInfo>(); /// <su...
a4a74175d270dfcd87dab01bac6242312a39840e
C#
christerk/StarsTNG
/Source/Stars.Core/Position.cs
3.6875
4
using System; namespace Stars.Core { public struct Position : IEquatable<Position> { public int X { get; set; } public int Y { get; set; } public Position(int x, int y) { X = x; Y = y; } public double DistanceTo(Position position) { var dx = position.X - X; var dy = position.Y - Y; re...
8c3abd5aef3bbe3498219d5959024f8740e4ee37
C#
Prometheus09/Calculator
/Calculator/Calculator.cs
3.15625
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Calculator { public abstract class Calculator { public void TurnOn() { Console.WriteLine("Calculator is on."); Console.WriteLine("Press CTRL-C t...
c94e8e1e04e6dd9a280b46b2c73068866066d5e9
C#
rosariomartone/ProjectTracker
/ProjectTrackerDataAccess/MenuVoicesDataAccess.cs
2.671875
3
using System; using ProjectTrackerEntities; using System.Configuration; using System.Data.SqlClient; using System.Data; using ProjectTrackerFactory; using System.Collections.Generic; namespace ProjectTrackerDataAccess { public class MenuVoicesDataAccess { public List<MenuBarVoices> GetMenuVoicesByMen...
5456ed34c25e60e5c38bc1198f66ad1fb135136c
C#
Prabath03Dot/Triple-DES-Image-Encryption
/Triple DES Image Encryption/TripleDES.cs
2.9375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Security.Cryptography; using System.IO; using System.Windows.Forms; namespace Triple_DES_Image_Encryption { public class TripleDES { private TripleDESCryptoServiceProvider t...
dd5dd63b18acc79b39381eead73e414a0587efd7
C#
marfig/webapi_angular_sample1
/WebApiEjemplo1/Controllers/ValuesController.cs
2.84375
3
using System; using System.Collections.Generic; using System.Linq; using System.Net; using System.Net.Http; using System.Web.Http; using WebApiEjemplo1.Models; namespace WebApiEjemplo1.Controllers { public class ValuesController : ApiController { static List<Pais> paises = new List<Pais>() { ...
d6515f87f154de061ba308f6133cec0e860f83e2
C#
EricLesch/EricLesch-gauges.net.async
/gauges/Service/GaugeService.cs
2.734375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Net.Http; namespace Gauges { public abstract class GaugeService { private string apiClientToken; public GaugeService(string apiClientToken) { ...
4613d4d521700eec711edb3486c8a78c7eb6ab89
C#
SergeiGolos/ComicViewer
/ComicViewer.Core/Interigators/TitleInterigator.cs
2.671875
3
using System; using System.Collections.Generic; using System.IO; using SharpCompress.Archives; namespace ComicViewer.Core.Interigators { public class TitleInterigator : IComicInterigator { public void Apply(ComicBookFile comic, FileInfo file, IArchive archive, IEnumerable<IArchiveEntry> pages) ...
8ecff0819bcd5a034bc8d1bbca5694666ddbd514
C#
fotodmitriru/TreeToFile
/CopyTreeToFile/Program.cs
3.171875
3
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text; using CsvHelper; namespace CopyTreeToFile { class Program { private static List<SourceTree> ChildTrees { get; set; } private static List<SourceTree> ParentTrees { get; set; } private...
e58aac8727c0f1cf4e3bdd0031ba4aad821ef14e
C#
RHillenbrand25/IT2030RHillenbrand
/Lab2/Lab2/Controllers/ProductController.cs
2.59375
3
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Mvc; namespace Lab2.Controllers { public class ProductController : Controller { // GET: /Product/ public string Index() { return "Product/Index is displayed.Index()"; ...
882bc3623553c9d4c55ad4a452162984d3242ebf
C#
fujinuji/LastLab
/Repositories/InMemoryRepository.cs
3
3
using FinalLaboratory.Domain; using FinalLaboratory.Validators; using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace FinalLaboratory.Repositories { public class InMemoryRepository<ID, E> : ICrudRepository<ID, E> where E : Entity<ID> { private List<E> _entitie...
4e91159f8c2baf599a6a04541e1fefd2dadddbb9
C#
crigney3/BinarySearchTrees
/BinarySearchTreeVisualizer/BinarySearchTreeVisualizer/RBNode.cs
3.03125
3
using System; using System.Collections.Generic; using System.Text; namespace BinarySearchTreeVisualizer { public enum Color { Red, Black } public enum Leaf { LEAF, not } class RBNode { protected RBNode rBNodeLeft; protected RBNode rBNodeR...
43a199140f77cd803ee1c7a1206c003efae0d1c4
C#
jegglestone/TheShuffler
/ShufflerLibrary/Helper/SentenceOrderReSetter.cs
2.703125
3
namespace ShufflerLibrary.Helper { using System; using Model; public class SentenceOrderReSetter { public static Sentence SetPeOrderAsc(Sentence sentence) { int[] pe_orders = new int[sentence.Texts.Count]; for (int index = 0; index < sentence.Texts.C...
06d4b5c00e1b406bfafab45ebd2f02eb008f9493
C#
AlejoR96/CrudEmpleadoHtml-.Aspx
/Ejercicio_AppWEB/ConexionMysqlEmpleados.cs
2.859375
3
using System; using System.Collections.Generic; using System.Linq; using System.Web; //Librerias de conexión a Mysql using MySql.Data; using MySql.Data.Types; using MySql.Data.MySqlClient; namespace Ejercicio_AppWEB { //clase de Conexion a Mysql public class ConexionMysqlEmpleados { // Inicio de c...
150034f92c7319138c7ff99fb82a0b07b5127e45
C#
shendongnian/download4
/first_version_download2/437029-38606687-123555198-2.cs
2.78125
3
static class IListExtensions { private static Random _rnd = new Random(); public static void PickRandom<T>(this IList<T> items) => return items[_rnd.Next(items.Count)]; }
40588a3b5a8ff449ae0d77b4bc8d5fb574563996
C#
shihab-js/ProgressBarExample-CSharp
/ProgressBarExample/Form1.cs
3.015625
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 ProgressBarExample { public partial class Form1 : Form { public Form1() ...
a716971329d7a9458f7e735650aa210a22d1fa39
C#
beckheng/WinServiceMaint
/FormMain.cs
2.671875
3
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.ServiceProcess; namespace WinServiceMaint { public partial class FormMain : Form { public FormMain() ...
92d460e41cdbcb320c88053776027b9d5e0ac592
C#
qwerfah/cnn-image-colorization
/CNN/Convolution/Layers/SoftmaxLayer.cs
3
3
using CNN.AuxiliaryStructures; using System; using System.Diagnostics; using System.Numerics; using System.Threading.Tasks; namespace CNN.Convolution.Layers { /// <summary> /// Слой функции активации Softmax. /// </summary> [Serializable] public class SoftmaxLayer : Layer { public over...
02797dc6e2bf6d910193e32e022f2f6b71e6f973
C#
cggarmendia/Poc.Rabbitmq.Core
/Poc.Rabbitmq.Core.Domain/Extension/StringExtension.cs
2.546875
3
using System; namespace Poc.Rabbitmq.Core.Domain.Extension { public static class StringExtension { public static string Replace(this string s, char[] separators, string newValue) { var temp = s.Split(separators, StringSplitOptions.RemoveEmptyEntries); return string.Join...
5f4957bcd728002a18b4e0a190f029476161ddbc
C#
zfaustk/Yiku
/Models/DataBase/SortHelper/SortHelper_Item.cs
2.78125
3
using System; using System.Collections.Generic; using System.Linq; using System.Web; namespace Yiku.Models.DataBase { public class SortHelper_Item { public SortHelper_Item(OrderHelper_Item_Enum order) { itemOrder = order; } private OrderHelper_Item_Enum ite...
380eec21aef408fafa87bc58daab9ed57e6f8266
C#
ainaea/Ebenezer-Aina--TypeB
/Question3/Employee.cs
3.515625
4
using System; namespace Question3 { public class Employee : IPayable { public string MailingAddress { get; set; } private decimal salary; public decimal Salary { get { return salary; } set { if (value > 0) { ...
8446b459d90c0554818b598c088b1e8766012f64
C#
shristoff/TelerikAcademy
/C#/PartI/6.Loops/04.N!divK!/N!divK!.cs
4.0625
4
/* Write a program that calculates N!/K! for given N and K (1<K<N).*/ using System; class NfactdivKfact { static void Main() { Console.Write("Please enter positive integer N = "); string Nstr = Console.ReadLine(); ulong N = ulong.Parse(Nstr); Console.Write("Please enter positi...
ded08bdbbae234dce95020ea22343584074bd6e3
C#
VladimirKhil/SI
/src/SIGame/SIGame/Controls/DropDownButton.cs
2.640625
3
using SIGame.Helpers; using System; using System.Windows; using System.Windows.Controls; namespace SIGame; /// <summary> /// Represents a button that shows drop-down menu on click. /// </summary> public sealed class DropDownButton : Button { public static readonly DependencyProperty DropDownProperty = De...
6701c39d6a4293166dfca963c3e348184b72ba2f
C#
pipeline-foundation/confluent-kafka-dotnet
/src/Confluent.Kafka/Internal/Extensions/Dictionary.cs
2.953125
3
using System.Collections.Generic; namespace Confluent.Kafka { /// <summary> /// Extension methods for the <see cref="IDictionary{TKey,TValue}"/> class. /// </summary> internal static class DictionaryExtensions { internal static string[] ToStringArray(this IDictionary<string, string> dic...
327f7b802d84122ff550d3d55c226c2955832106
C#
ornamental/persistent-structures
/PersistentCollections/LazilyReversedStack.cs
2.921875
3
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; namespace PersistentCollections { internal sealed class LazilyReversedStack<T> : Thunk<IPersistentStack<T>>, IPersistentStack<T> { public LazilyReversedStack(IPersistentStack<T> original) ...
fa95b0b3bd7248b814e66bbe77ee61917a431eb5
C#
shankarmadeshvaran/Xamarin_MVVM
/SlidingMenu/Service/Contacts.cs
2.546875
3
using System.Collections.Generic; using System.Collections.ObjectModel; using System.Threading.Tasks; namespace SlidingMenu.Models { public class Contacts { public static IEnumerable<Contact> Get() { return new ObservableCollection<Contact> { new Contact...
0c07328a1c34a950436354078d12779d9aba49c5
C#
yong10/Iron_Ninja
/Models/SweetTooth.cs
3.15625
3
using System; namespace Iron_Ninja.Models { class SweetTooth : Ninja { // provide override for IsFull (Full at 1500 Calories) private int Limit = 1500; public override bool IsFull { get { return calorieIntake >= Limit; } ...
b66558f9ff8ef5452ecfccbde0fdfec3020c961d
C#
netorochaa/grelhamef
/Grelha MEF/MatrixUtil.cs
2.984375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Grelha_MEF { public static class MatrixUtil { //MATRIZ INVERSA DOC MICROSOFT public static double[][] MatrixCreate(int rows, int cols) {   // creates a matrix i...
d3b597009285800275e989c76f3697c705b87cd5
C#
thuctapnhom13createdbytl/AllProjectThucTapNhom
/QLHS/QLHS/DAO/Diem_DAO.cs
2.53125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using QLHS.DTO; using System.Data; namespace QLHS.DAO { public class Diem_DAO { private static Diem_DAO instance; public static Diem_DAO Instance { get ...
d723ae21c8ff450ffdd034ce18d5476e12e910bf
C#
navayli/TicketSell
/OnlineTicketDeskUI/Forms/AddCardForm.cs
2.546875
3
using OnlineTicketDeskUI.Core; 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 OnlineTicketDeskUI { public partial class AddCardForm : For...
02e2888b3732b174fe48efcb2d4fe4174e7fdec1
C#
nafetz/SE
/LiftSimulation/LiftSimulation/Log.cs
3.21875
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; namespace LiftSimulation { public static class Log { #region Member private static string _path = System.IO.Path.GetTempPath(); private static StreamWriter _logger = null; p...
444f25439f5b58aa60356d9297fc1275da277b3e
C#
yiuweiping/orm
/Reflection/DynamicHandlerCompiler.cs
2.53125
3
using System; using System.Collections.Generic; using System.Linq; using System.Reflection; using System.Reflection.Emit; using System.Text; using System.Threading.Tasks; using Zhengdi.Framework.Data.Entity; namespace Zhengdi.Framework.Reflection { public class DynamicHandlerCompiler<T> { ...
21125c8373df55f055d61ebed5ada0543f81a04b
C#
ioane37/Weekly-Game-Jam---Week-104
/Weekly Game Jam - Week 104/Assets/Scripts/AudioManager.cs
2.71875
3
using UnityEngine; using System.Linq; public class AudioManager : MonoBehaviour { [SerializeField] SoundAudioClip[] soundAudioClips = null; public static AudioManager Instance { get; private set; } AudioSource audioSource = null; public enum SoundType { Chasing, Background }...
54596551301fc3819e5e2eaffdb940237d47f36d
C#
SupremeKenny/Project-Bier
/Repository/Interfaces/IProductRepository.cs
2.890625
3
using System; using System.Collections.Generic; using Project_Bier.Models; using Project_Bier.Models.ViewModels; using Project_Bier.Pagination; namespace Project_Bier.Repository { /// <summary> /// Interface that describes what kind of methods a Product Repository class /// should have. /// /// De...
f31cde12506b620043198881b3211325337c1b7c
C#
Shiling1234/AsyncSocketServer
/PublicLibrary/Model/ServerInfo.cs
2.65625
3
using System; using System.Collections.Generic; using System.ComponentModel; using System.Linq; using System.Text; using System.Threading.Tasks; namespace PublicLibrary.Model { [Serializable] public class ServerInfo:INotifyPropertyChanged { private string m_name; private int m_id; priva...
7271655e3c0fde99f481bb0eb70872be12fc7fbd
C#
LOyster1/Rilke-Schule-Student-Management-MVC-asp.Net
/Rilke_Schule_Student_Management/Models/Guardianship.cs
2.546875
3
using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; namespace Rilke_Schule_Student_Management.Models { public class Guardianship//--Class is for connecting parents with students { [Key] [Required] public int Guardianship_I...
ec4bda6569c3b730f3014359805894836896025c
C#
shendongnian/download4
/first_version_download2/436810-38583631-123465698-2.cs
3.203125
3
public static readonly byte[] PngSignature = { 0x89, 0x50, 0x4E, 0x47, 0x0D, 0x0A, 0x1A, 0x0A }; public static byte[] ImageToBinary(string imagePath) { if (!File.Exists(imagePath)) // Check file exist throw new FileNotFoundException("File not found", imagePath); if (Path.Get...
0b83e51be0c78c6dd726d1a56fdda58e20d1ee5b
C#
tofasuriawan/learn-csharp
/MoneyTracker/MoneyTracker/ChangePassword.cs
2.734375
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 MoneyTracker { public partial class ChangePassword : Form { public ChangePassw...
11dc768860f20287fe3fbf92cd2b8b80ef44887d
C#
MonikaMaria/Calculator
/Calculator.Tests/CalcTests.Power.cs
2.953125
3
using System; using NUnit.Framework; namespace Calculator.Tests { public partial class CalcTests { #region Power [Test] public void Power_negative_fraction_positive_power_value() { Fraction f = new Fraction(-5, 6); int g = 2; ...
2eb6552282fc53201193f7c2e8d9577a6dbbbac5
C#
yijunyu/demo
/datasets/corefx-1.0.4/src/System.ComponentModel.TypeConverter/src/System/ComponentModel/CollectionChangeAction.cs
2.6875
3
// Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. // See the LICENSE file in the project root for more information. namespace System.ComponentModel { /// <summary> /// <para>Specifies how the collection is changed.</para>...
02899017e570f6b5f9753f646128e17fd85185f1
C#
CrispyTofuGames/MergeMachos
/Assets/Plugins/Nutaku/Scripts/QueryParameterBuilder.cs
2.96875
3
using System; using System.Collections.Generic; using Nutaku.Unity.Utils; namespace Nutaku.Unity { /// <summary> /// Builder class that builds query parameters. /// </summary> public class QueryParameterBuilder { protected Dictionary<string, object> _parameters = new Dictionary<string, object>(); ...
2b01120d438bdcd1ae92639566974cc9ed3da46a
C#
creeves1287/cci-solutions
/Ch3 - Stacks and Queues/StacksQueue/StacksQueueTests/StacksQueueTests.cs
3.015625
3
using System; using Microsoft.VisualStudio.TestTools.UnitTesting; using StacksQueue; namespace StacksQueueTests { [TestClass] public class StacksQueueTests { private readonly int _size = 10; [TestMethod] public void MyStacksQueueTests() { IStacksQueue<int> stac...
8373ea95b7cd664f74abe38819c3238ac584f670
C#
Spencerstf/Civilian-Industries
/Persistence/CivilianCargoExtensions.cs
2.84375
3
using Arcen.AIW2.Core; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace SKCivilianIndustry.Persistence { public static class CivilianCargoExtensions { // This loads the data assigned to whatever ParentObject you pass. So, say...
408b1f0b0c954be5ba8cf5fabeee2d6f2359d965
C#
TerlanQurbanov/C-Example
/Bolum10_FormlarveKontroller/textBox_Reverse/Form1.cs
2.84375
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 textBox_Reverse { public partial class Form1 : Form { public Form1() {...
a3dac6df9cf19adb8255dcb0694ab373c26d846f
C#
mastertnt/XScriptedObject
/XScriptedObject.Tests/Tests.cs
2.9375
3
using NUnit.Framework; using Sprache; namespace XScriptedObject.Tests { /// <summary> /// Global class for all tests. /// </summary> public class Global { /// <summary> /// Checks the integer. /// </summary> [Test] public static void CheckInteger() {...
1562e1947eb277e618e9eac66e68caadab5d4635
C#
thomshib/LeetCode
/LeetCodeTest/DataStructures/BinaryIndexedTreeTests.cs
2.8125
3
using System; using System.Collections.Generic; using System.Text; using Microsoft.VisualStudio.TestTools.UnitTesting; using LeetCode.DataStructures; namespace LeetCodeTest.DataStructures { [TestClass] public class BinaryIndexedTreeTests{ [TestMethod] public void BinaryIndexedTreeSuccess (){ ...
0e1cf8d0f646caaa29725ea97ea0f52b9cdc9e50
C#
SecretNest/Fraction
/Fraction/Fraction_Properties.cs
3.171875
3
using System; using System.Text; namespace SecretNest { public partial struct Fraction { public bool Sign { get { return sign > 0; } } public long Integer { get { return sign * (long)integer; } set { if (value >= 0) ...
f6715db7efa14ffefd1dcc26691ada46c3c66561
C#
Blackbandit1804/RageMP-1.1.0-Template
/dotnet/resources/Roleplay/PlayerAPI/LoginHandler.cs
2.703125
3
using GTANetworkAPI; using MySql.Data.MySqlClient; using System; using System.Collections.Generic; namespace Roleplay.PlayerAPI { class LoginHandler : Script { [RemoteEvent("LoginAccount")] public static void LoginPlayer(Player c, string username, string password) { if (c.H...
abfd5f0ed10eaf5abc290f6826dc2c1a1dbd5248
C#
farcaneageorge/POO2020
/PublisherAndSubscribers/PublisherAndSubscribers/Program.cs
2.578125
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace PublisherAndSubscribers { class Program { static void Main(string[] args) { Publisher p = new Publisher(); SubscriberA a = new Su...
04a76c5ec7af5d3c5dd57adf788b60886b24ba53
C#
WZStephen/Software-Integration-and-Engr
/Assignment9/WebApplication1/WebApplication1/utilities.cs
2.984375
3
using System; using System.Collections.Generic; using System.Diagnostics; using System.Linq; using System.Threading; using System.Web; namespace WebApplication1 { public class utilities { public static List<KeyValuePair<string, int>> NameNode(string data, int totalThreads) { List<s...
13540b09838deb1d28155465af40541594a273da
C#
pbishal/UserRegistrationMSTest
/UserRegistrationTest/UserRegistrationCustomException.cs
3.1875
3
using System; using System.Collections.Generic; using System.Text; namespace UserRegistrationTest { public class UserRegistrationCustomException : Exception { public enum ExceptionType { INVALID_FIRSTNAME, INVALID_LASTNAME, INVALID_MOBILENUMBER, INVALID_EMAIL, INVALID_PSSWORD ...
bfbdfe2467bf6bf5b2cfa5d76ba4269447e6c950
C#
zmiao0219/DesignPatterns
/StructuralPatterns/Decorator/Definition.cs
3.234375
3
using System; using System.Security.Cryptography; namespace StructuralPatterns.Decorator { public abstract class Component { public virtual void Operation() { Console.WriteLine("basic component operation."); } } public class ConcreateComponent : Component { ...
519975b5b0f9f7106bbbc4e3fdfbf681d10eff68
C#
JuanRodriguezGiles/TSDV_desarrollo02_tp09_inventario
/Inventario/Assets/Scripts/Items/WeaponObject.cs
2.625
3
using UnityEngine; public enum WeaponType { Sword, Mace, Spear, Axe } [CreateAssetMenu(fileName = "Weapon Object", menuName = "Inventory/Items/Weapon")] public class WeaponObject : ItemObject { public WeaponType weaponType; public int attackValue; void Awake() { type = ItemType....
a1998393cf6d5a2e4f200439739dfdf9db28147e
C#
matthewAURA/ortem
/Assets/Scripts/Grid.cs
2.578125
3
using UnityEngine; using System.Collections; using System.Collections.Generic; public class Grid : MonoBehaviour { private static Grid staticGrid; public static Grid getGrid() { return staticGrid; } public int width; public int height; public int gridSize; public GridSquare gridSquare; private Place...
d16754f4f1de4cdac6f7f105bb81bf8daa537cf4
C#
jervie28/ProjectX
/UXManager/Keyboard.cs
2.515625
3
using System; using System.Collections.Generic; using System.Data; using System.Linq; using System.Text; using System.Windows.Forms; using MetroFramework.Controls; using Rms.BusinessLogic; namespace UXManager { public static class Keyboard { public static void PreventeDelete(this KeyEventArgs e) ...
8aa93b53aca57f4e0aa4723ad1b920f871a6b105
C#
potokki/Seegull
/PVP/PVPAssister/Mingwen/MingwenLevelOverall.cs
2.8125
3
using System; using System.Collections.Generic; using System.Linq; using PVPAssister.CSV; namespace PVPAssister.Mingwen { public class MingwenLevelOverall { private const double ScoreMin = 9.8; private const int ScoreMid = 11; private const int ScoreAdvanced = 14; private const...
b34329c5aea6b462a9191774cb9cfd5ab8cada63
C#
beastsak/Space-Shooter
/Assets/Scripts/GamePlay Elements/GameSession.cs
3.015625
3
using System.Collections; using System.Collections.Generic; using UnityEngine; using System; //this is publisher public class GameSession : MonoBehaviour { private int score = 0; private event Action<int> OnScoreUpdate; private static GameSession instance = null; public void Awake() { ...
d913239c694df2f89020bec4f1a8f5a2d6547e77
C#
ulanscodes/atata
/src/Atata/Attributes/WindowTitleAttribute.cs
2.546875
3
namespace Atata { /// <summary> /// Specifies the window title of <see cref="PopupWindow{TOwner}"/> page object. /// This title can be used to identify the popup window among others when there can be several opened popups at the same time. /// It is used by <see cref="PopupWindow{TOwner}"/> togeth...
a4d77cf41ef61850faa2cfe4608cb2fbef98de48
C#
dangduc123/duc0307
/dienTichHinhTron/Program.cs
3.375
3
/*Minh họa xử lý ngoại lệ*/ using System; namespace dienTichHinhTron { class Program { const double PI = 3.1416; static void Main(string[] args) { double r = 0, s = 0; do { Console.WriteLine("\nNhap vao ban kinh r:"); ...
e55488367860bb922eaae4ad7d637493ea6c09eb
C#
Media-Hub/VNACCS
/StyleManagerAmbient.cs
2.53125
3
using System; using System.Collections.Generic; using System.Text; using System.Drawing; using System.ComponentModel; using System.Windows.Forms; namespace DevComponents.DotNetBar { /// <summary> /// Manages whether ambient property settings (BackColor, ForeColor etc.) are applied to child controls of the form...
415b616ada4716424f26dca34c3436f4288ffa2b
C#
alanlong9278/shifa
/App_Code/db.cs
2.796875
3
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Data; using System.Data.SqlClient; using System.Configuration; /// <summary> ///db 的摘要说明 /// </summary> public class db { public db() { // //TODO: 在此处添加构造函数逻辑 // } /// <summary> /// 连接数据库 /// </summa...
cb493c17c02acfbed364d811ba551e1ab5e2605c
C#
AveryHu/DesignPattern
/MediatorPattern/Colleague.cs
3.25
3
using System; namespace MediatorPattern { public abstract class Colleague { protected Mediator _mediator; public virtual void SetMediator(Mediator med) { this._mediator = med; } public abstract void SendMission(HeroType targettype, string mission); ...
901b26afcf311fdd45b6630900d088836ff8e8fb
C#
davidbedok/oeprogvep
/winform/Bloxorz/Bloxorz/Block.cs
3.234375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Drawing; namespace Bloxorz { public class Block { // test commit private Position b1; private Position b2; public Position B1 { get { return this.b1; } ...
4f40d2f3e437956a3145888a887e52231c530907
C#
shendongnian/download4
/code1/158694-53555022-186876610-12.cs
2.609375
3
string query = @"UPDATE staging.TestTable SET Column1 = 2"; using (SqlConnection conn = new SqlConnection(conn2)) { try { conn.Open(); using (TransactionScope ts = new TransactionScope()) { conn.Enli...
0f2199cca8ee622d07faa257aebe85baee044b2d
C#
karladenisse3/KarlaFernandez3A
/Program4.cs
3.59375
4
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; /*Crear un programa para calcular el salario semanal de unos empleados a los que se les paga 15 dólares por hora si éstas no superan las 35 horas.Cada hora por encima de 35 se considerará extra y...
76a1aef74c8ec22c8e19eb3be46120a236586ed8
C#
msarge2015/KiCASS
/Models/MainWindowModel.cs
2.546875
3
using LaptopOrchestra.Kinect.ViewModel; using System.ComponentModel; using System.Diagnostics; namespace LaptopOrchestra.Kinect.Model { public class MainWindowModel : ViewModelBase { #region Properties private string _iconPhoto; public string IconPhoto { get { retur...
3069e9096c9d060567d631647b7226a5628ae1a6
C#
longsamaa/banthuoc
/QuanLyBenhNhan/Model/Model_qlbenhan.cs
2.515625
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Data; using MySql.Data.MySqlClient; namespace QuanLyBenhNhan.Model { class Model_qlbenhan { public bool Them_BenhAn(int idbenhnhan,byte[] image,String trieuchung) { ...
38a76311ea37becbbc29e2d1961a6fb3a507edef
C#
Noixelfer/Evolution
/Evolution/Assets/Scripts/Actions/Essential/Sleep.cs
2.796875
3
using Evolution.Character; using System.Collections.Generic; namespace Evolution.Actions { public class Sleep : BaseAction { public override string ID => "Sleep"; public override string Description { get; protected set; } = "Sleeping"; public override HashSet<string> Effects { get; set; } = new HashSet<string...
b56b972c995748a8102f89f0589a4ab30bbc9623
C#
Adam-Bengtsson/KingPim
/Infrastructure/CategoryExtensions.cs
2.640625
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using KingPim.Models; using Microsoft.AspNetCore.Mvc.Rendering; namespace Infrastructure { public static class CategoryExtensions { public static List<SelectListItem> ToSelectList(this IEnumerable<Category> categorie...
cb145b5cbf6e7aa31f2cb427445b9bc8cf057f5d
C#
ssajous/SSChess
/src/SSChess.Core.Tests/Model/GamePlay/RookTests.cs
2.71875
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using NUnit.Framework; using FluentAssertions; using SSChess.Core.Model.Gameplay; namespace SSChess.Core.Tests.Model.Gameplay { [TestFixture] public class RookTests { p...
f29763be08f404dac26589e1f869fc90d83614da
C#
MRGRD56/MgTube
/MgUrlParser/MgUrl.cs
2.71875
3
using System; using System.Collections.Generic; using System.Linq; namespace MgUrlParser { public class MgUrl { public MgUrl(string url) { Url = url; Parse(); } public string Url { get; private set; } public string Protocol { get; private set; }...
543db40ac9537348835288b7e7840029d0725841
C#
Empired/Rebus
/src/Rebus.Tests/Integration/TestSubscribeUnsubscribe.cs
2.53125
3
using System; using System.Collections.Generic; using System.Threading; using NUnit.Framework; using Shouldly; using System.Linq; namespace Rebus.Tests.Integration { [TestFixture] public class TestSubscribeUnsubscribe : RebusBusMsmqIntegrationTestBase { const string PublisherInputQueue...
8db1afb1d9ec2469d8dfb0270a1b1fe52ae8d69d
C#
ericpohl/EvernoteRecipesByTag
/Program.cs
2.5625
3
using System; using System.Collections.Generic; using System.Globalization; using System.IO; using System.Linq; using Evernote.EDAM.NoteStore; using Evernote.EDAM.Type; using EvernoteSDK.Advanced; namespace EvernoteRecipesByTag { class Program { static void Main(string[] args) { s...
261d4c92cd422b63dfd8fda6c796b3af25121152
C#
PaulKGray/TemplateGraySkull
/Domain/ParentItem.cs
2.59375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Template.Domain { public class ParentItem : DomainBase { public virtual int ParentItemid { get; set; } public virtual string Name { get; set; } public virtual string D...
b33835eef85bd57aa5415acb8cba8602fec073ea
C#
sebastianpiascik/CS_OOP
/02Konstruktory/Punkt.cs
3.234375
3
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace _02Konstruktory { struct Punkt { private int x; private int y; public Punkt(int x, int y) { this.x = x; this.y ...
01639c5b76982038cf63cace9c4258f57a016857
C#
punker76/RayCarrot.RCP.Metro
/RayCarrot.RCP.Metro/DataModels/GameFileLink.cs
2.796875
3
using MahApps.Metro.IconPacks; using RayCarrot.IO; namespace RayCarrot.RCP.Metro { /// <summary> /// A game file link which can be accessed from the game /// </summary> public class GameFileLink { /// <summary> /// Default constructor /// </summary> /// <param name=...
19d5ff2a6031822df6b6f1b7843f0d5c7b3987f0
C#
ozgurerbulan/mekatronik-sistem-tasar-m-
/KonsolUygulamasi.cs
3.359375
3
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApplication1 {     class Program     {         static void Main(string[] args)         {             int i = 0;             string id = "";             string data = Fil...
a77c8081ef7694399a66573a844ed5b4bfb78303
C#
jander-msft/adventofcode
/AOC2020/Direction.cs
3.546875
4
using System; namespace AOC2020 { public enum Direction : byte { East, North, West, South } public static class DirectionExtensions { public static Direction RotateCW(this Direction direction, int count = 1) { while (count-- > 0) ...
dbffa8200c9e3c28d235755b400647f2999ec49e
C#
liang0612/QNAutoTask
/src/QNAutoTask/Asset/AssetXmlHelper.cs
2.5625
3
using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows; namespace QNAutoTask.Asset { public class AssetXmlHelper { public static string GetAsset(string assetName) { string packUri = "...
917d390f7660cf49a915d9f57be3fd3ce28f5da3
C#
adizhavo/ECS
/ECS/EntityMatcher.cs
3.453125
3
using System; using System.Linq; using System.Collections.Generic; namespace ECS { // Will hold all the entities and return a specific pool of them, like a search engine of entities and components // this can be extended in much more methods public static partial class EntityMatcher { // All entities crea...
ea9a604d603bd40e3b543b6ef11efbbb9b8c3c63
C#
Bondorudo/BulletHellGameRepo
/Scripts/Units/Enemies/ShieldScript.cs
3
3
using System.Collections; using System.Collections.Generic; using UnityEngine; public class ShieldScript : MonoBehaviour { private bool isTouchingWall; // When colliding with wall set isTouchingWall to true private void OnCollisionEnter(Collision collision) { if (collision.gameObject.layer == ...
a9ead23a8bf1f34a8ea7fc54134a9bb1dbd0ca36
C#
shino09/CARGAFACTURAS
/WEB_CLIENTE/Models/ClsRutinasGenerales.cs
2.828125
3
using System; using System.Collections.Generic; using System.Linq; using System.Web; namespace WEB_CLIENTE.Models { public class ClsRutinasGenerales { public void eLog(string mensaje) { String ArchLog = AppDomain.CurrentDomain.SetupInformation.ApplicationBase + @"ProcesoAutomatico...