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 |
|---|---|---|---|---|---|---|
b55e735a59b4b4899b36c92f69cdc7706f90725e | C# | DimitarSD/Telerik-Academy | /01. Programming/04. High-Quality Code [C#, JavaScript]/05. Control Flow, Conditional Statements and Loops/RefactorExamSolutions/Cube.cs | 3.515625 | 4 | namespace RefactorExamSolutions
{
using System;
public class Cube
{
public static void Main()
{
string sizeAsString = Console.ReadLine();
int size = int.Parse(sizeAsString);
Console.Write(new string(' ', (2 * size - 1) - size));
Console.Writ... |
aab8286cb203891c06fef7b3c53787097601b492 | C# | jan-pavlovsky/VHVisualization | /Structures/SCluster.cs | 3.0625 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Drawing;
using Emgu.CV;
using Emgu.CV.Structure;
using Emgu.CV.CvEnum;
namespace VHVisualisation
{
/// <summary>
/// A mean/cluster in the k-means algorithm.
/// </summary>
public class S... |
45a1333924262ed9858b32b088bde2dfcd899327 | C# | mazzafabio/ssai | /SSAI/Entity/Repository/ProductRepository.cs | 2.65625 | 3 | using Microsoft.EntityFrameworkCore;
using SSAI.Data;
using SSAI.Entity.DB;
using SSAI.Entity.IRepository;
using SSAI.Helpers.Pagination;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
namespace SSAI.Entity.Repository
{
public class ProductRepository : IProductRe... |
6c2a1eef183b72e0a367a3969290d6837ca72bfd | C# | happylearnerOne/MyMvcProject | /MyMvcProject/Models/Converter/Converter2.cs | 2.890625 | 3 | using Newtonsoft.Json;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Reflection;
namespace MyMvcProject.Models.Converter
{
public class Converter2<T> where T : new()
{
public static bool Compare(T obj1, T obj2)
... |
d951f942fcfbcf74f5801515dc2efae82251c757 | C# | PeterEngelbrektsson/PragueParkingOO | /MyCompany/Storage.Biz/Exceptions.cs | 2.953125 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace MyCompany.Storage.Biz
{
/// <summary>
/// If the registration number already exists
/// </summary>
public class RegistrationNumberAlreadyExistsException : Exception
{
... |
539a0de0cff672bb95c644ba652c4c4773b1a3fe | C# | Imran-cse/ArtGallery | /ArtGalleryV2/Handler1.ashx.cs | 2.75 | 3 | using MySql.Data.MySqlClient;
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.Web;
namespace ArtGalleryV2
{
/// <summary>
/// Summary description for Handler1
/// </summary>
public class Handler1 : IHttpHandler
{
public void Proc... |
f86f675d638304131d26d37ad53bd6298ea5113b | C# | maxarnheiter/THD1v2 | /Assets/Scripts/ExtensionMethods.cs | 2.875 | 3 | using UnityEngine;
using System.Collections;
public static class ExtensionMethods
{
public static Texture2D GetSpriteTexture(this Sprite sprite)
{
var texture = new Texture2D ((int)sprite.rect.width, (int)sprite.rect.height);
texture.SetPixels (sprite.texture.GetPixels ((int)sprite.rect.x, (int)sprite.... |
2753fe4dbd58fb096fb807041c3a33f335b6dbad | C# | tintoy/msbuild-project-tools-server | /src/LanguageServer.Common/Utilities/VSCodeDocumentUri.cs | 3.15625 | 3 | using System;
using System.IO;
namespace MSBuildProjectTools.LanguageServer.Utilities
{
/// <summary>
/// Helper methods for working with VSCode document <see cref="Uri"/>s.
/// </summary>
public static class VSCodeDocumentUri
{
/// <summary>
/// Get the local file-system pa... |
3da54c5f98c0dd4f0e5a04814ac8c50e2b097935 | C# | marius-cismaru/Infonova-WMS | /04. Archives/SiriusWLM/EntityModels/Entities/Companies/Company.cs | 2.578125 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel;
namespace Sirius.EntityModels
{
public partial class Company
{
public string ClientList
{
get
{
string result = "- Niciunul -";
... |
de8718a764bc90c9692fc84b1a106b2a2ae425c3 | C# | kristiansja/RoR2-MM | /RoR2MM/Form1.cs | 2.796875 | 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;
using System.IO; //add this namespace also
namespace WindowsFormsApp4
{
public parti... |
08dab7ce23d7ba74f86c8137f37e7038453796f0 | C# | QPC-database/msrecruit-scheduling-engine | /common/HR.TA.CommonLibrary/HR.TA.Common/Microsoft.CommonDataService.Common/Internal/Contract.cs | 2.6875 | 3 | //-----------------------------------------------------------------------
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
//-----------------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Globali... |
ee96f5e32feab18562bfea9f06012d6d9c87193f | C# | mumutongxueY/GUGU-RPG | /Assets/Scripts/Game/Input/Common/InputCellManager.cs | 2.703125 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using UnityEngine;
namespace RPG.InputSystem
{
public class InputCellManager
{
private static List<InputCell> cells = new List<InputCell>();
// 添加单元格
publi... |
03572852add913a1dab1bc119aade0db83f1253d | C# | sassembla/cs-wasm | /libwasm/SectionName.cs | 3.453125 | 3 | using System;
namespace Wasm
{
/// <summary>
/// /// Represents a section's header.
/// </summary>
public struct SectionName : IEquatable<SectionName>
{
/// <summary>
/// Creates a section name for a non-custom section with the given section code.
/// </summary>
/// ... |
288ea42359a38392e2e8660f93f149cb39a85994 | C# | the-javascript-school/McAfee-AspNetMvc | /Day-1/UnitTestablityDemo/UnitTestablityDemo/Greeter.cs | 3.265625 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace UnitTestablityDemo
{
public interface IGreeter
{
string Greet(string name);
}
public class Greeter : IGreeter
{
ITimeService timeService;
public Gr... |
0e2dd6a20decdc7608fe2e4dfe8c2039b946c415 | C# | deesaa/JDS_Lib | /JDS/ReactiveCore.cs | 2.984375 | 3 | using System;
using System.Collections.Generic;
namespace JDS
{
public interface IReactiveCoreObserver<T>
{
void OnKeyValueChanged(T key, object nextValue);
}
/// <summary>
/// Reactive Core
/// </summary>
/// <typeparam name="T"></typeparam>
public class ReactiveCore<T>
... |
9f45151ec41d35ebf0384364ba743ff9e2f86183 | C# | DQT7/C-Library- | /0.11_Encapsulation/bankProtected.cs | 2.671875 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace _0._11_Encapsulation
{
class bankProtected
{
public void CloseAccount()
{
ApplyLateFees();
}
protected void ApplyLateFees()
... |
84fc70c8dc66f02c5b4eaa4fa551bebbfb8f47dd | C# | brian8181/SecureStorage | /CertSigningTest/Program.cs | 3.171875 | 3 | using System;
using System.Collections.Generic;
using System.Text;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
namespace CertSigningTest
{
class Program
{
static byte[] Sign(string text, string certSubject)
{
// Access Person... |
30dd0ca8fbed768bc1a95e343aed116a953ef341 | C# | pigisyou70/Thunder | /Thunder/Meteorite.cs | 3.109375 | 3 | using System.Drawing;
namespace Thunder
{
class Meteorite
{
int width = 79, height = 200;
Point postion;
bool blife;
public int Width { get { return width; } set { width = value; } }
public int Height { get { return height; } set { height = value; } }
// 假如位置達到最... |
c9fa47e1d0fa336e73dd6a4d99f44e09698e8c59 | C# | antonyukmaryana/Restaurants | /Restaurants/Models/Restaurant.cs | 3.0625 | 3 | using System.Collections.Generic;
using System;
using MySql.Data.MySqlClient;
namespace Restaurant.Models
{
public class Restaurant
{
private string _name;
private int _cuisineId;
private string _cuisine;
private int _id;
public Restaurant(string name, int cuisineId, string cuisine, int id = 0... |
cb8e2dacd213139a03a13c1e0475ac5a286fd370 | C# | Bastille-ID/Bastille.Id.Core | /src/Data/RedisManager.cs | 2.703125 | 3 | /*
* Bastille.ID Identity Server
* (c) Copyright Talegen, LLC.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
* Unless required by appli... |
76731dcbb2c77a049adb3c6a803a3e70a22189b7 | C# | maikebing/turtlebuild | /src/Libraries/QQn.TurtleUtils/Tokens/Definitions/TokenItemBase.cs | 2.890625 | 3 | using System;
using System.Collections.Generic;
using System.Reflection;
namespace QQn.TurtleUtils.Tokens.Definitions
{
/// <summary>
///
/// </summary>
public abstract class TokenItemBase
{
readonly Type _valueType;
/// <summary>
/// Initializes a new instance of the <see cref="TokenItemBase"/> class.
... |
615f743d134f3beed99aa8398127635c65877702 | C# | eXacT39/Projects | /Gun.cs | 3.109375 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Media;
using System.Drawing;
namespace Lab1_3
{
public abstract class Gun
{
public int ClipSize;
public int Dispersion;
protected SoundPlayer soundShoot;
private readonly SoundPla... |
db33eb355b0fff5091e10bb38c9fe3de9178e82f | C# | Sindrener/mod1_proc | /mod1_proc/mod1_proc/Semafor.cs | 3.15625 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace mod1_proc
{
class Semafor
{
private int s;
private LinkedList<Process> queue;
public Semafor(int i)
{
s = i;
queue = new LinkedL... |
f64210da74f781800d1a99e2fbac98c8782400af | C# | George-E-M/InstilleryScoreboards | /Scoreboards.Data/Validators/NotEqualAttribute.cs | 2.90625 | 3 | using Microsoft.AspNetCore.Mvc.ModelBinding.Validation;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Globalization;
/**
* Validates 2 text/select fields and
* Throws error if 2 text fields are equal
*/
namespace Scoreboards.Data.Validators
{
[Attrib... |
c790978e5493fb22118550d0dad680d632d439b8 | C# | wtm1997/jianghu | /Assets/Scripts/Tools/ReadExcel/ReadExcel.cs | 2.78125 | 3 | using System.Collections;
using System.Collections.Generic;
using System.IO;
using UnityEngine;
using System.Data;
using Excel;
public static class ReadExcel
{
public static List<string> GameReadExcel(string path)
{
FileStream stream = File.Open(Application.dataPath + path, FileMode.Open, FileAcc... |
6a5da4323b1fce2b45fd91ee61d380077cec604f | C# | shendongnian/download4 | /code4/730291-17710342-43876652-2.cs | 2.828125 | 3 | int count=0;
int blocksize = 2205;
List<List<byte>> blocks = ARCHIEVE_BUFFER
.GroupBy( _ => count++ / blocksize)
.Select(x=>x.ToList())
.ToList();
|
d27478aecb6d6c3b4b6b6667da4fd66a26936cf4 | C# | cikie100/EF_Opdracht | /Library/DatabankInitialiseer.cs | 2.71875 | 3 |
using Library.Model;
using Library.Objects;
using Microsoft.Data.SqlClient;
using Microsoft.EntityFrameworkCore;
using System;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using System.Linq;
namespace Library
{
public class DatabankInitialiseer
{
string path = @"D:\Use... |
a6860d831b55ab8fe4fc4293d779f14db095cc87 | C# | Apathak-tba/ApathakMailTest | /VolmaxF2/App_Code/BasePage.cs | 2.640625 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using VCM.Common;
using VCM.Common.Log;
public class BasePage : System.Web.UI.Page
{
public BasePage()
{
//
// TODO: Add constructor logic here
//
}
private SessionInfo _session;
public SessionInfo CurrentSession
... |
484e1c5ca40b9d36264fb4ceeee6cd5c1d849628 | C# | Dev-Ayush/HackerRank | /Left_Rotate_The_Array.cs | 3.734375 | 4 | //https://www.hackerrank.com/challenges/linkedin-practice-array-left-rotation
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Left_Rotate_The_Array
{
class Program
{
static void Main(string[] args)
{
... |
3321d20c05aa444e2d3caa91d9fffef8e0806993 | C# | sinthi315/Text-Summarizing-Tool | /Summarizer.cs | 2.796875 | 3 | using iTextSharp.text.pdf;
using iTextSharp.text.pdf.parser;
using System.IO;
using System.Security.Permissions;
using System.Text;
namespace Summary
{
public class Summarizer
{
public Summarizer()
{
}
public static SummarizedDocument Summarize(SummarizerArgument... |
5d67c388ce6fd7ee5fd7786ab832899e219a6a91 | C# | neurophotometrics/neurophotometrics | /Neurophotometrics/AutoCropCapture.cs | 2.59375 | 3 | using Bonsai.Spinnaker;
using OpenCV.Net;
using SpinnakerNET;
using System;
namespace Neurophotometrics
{
class AutoCropCapture : SpinnakerCapture
{
readonly Photometry processor;
public AutoCropCapture(Photometry photometry)
{
processor = photometry;
}
pu... |
1432353d1c9b45e03ffb7e1d4307b3d45f9b8d59 | C# | wartaveda/FaceRecognitionDotNet.Server | /examples/FaceDetection/Program.cs | 3.25 | 3 | using System;
using System.Drawing;
using System.IO;
using FaceRecognitionDotNet.Client.Api;
namespace FaceDetection
{
internal class Program
{
#region Methods
private static void Main(string[] args)
{
if (args.Length != 2)
{
... |
1da532b52585be6739c2244a7f107007d993f0d1 | C# | dotnet/docs | /samples/snippets/csharp/VS_Snippets_CLR/conceptual.regex.language.characterclasses/cs/whitespace1.cs | 3.46875 | 3 | // <Snippet10>
using System;
using System.Text.RegularExpressions;
public class Example
{
public static void Main()
{
string pattern = @"\b\w+(e)?s(\s|$)";
string input = "matches stores stops leave leaves";
foreach (Match match in Regex.Matches(input, pattern))
Console.WriteLine(matc... |
e0029f2c58531ffeea10726ecad4de4079683c2d | C# | mrurb/WurmAssistant3 | /src/WurmApi/WurmApi/WurmServerInfo.cs | 2.671875 | 3 | using System;
namespace AldursLab.WurmApi
{
public class WurmServerInfo
{
public WurmServerInfo(string name, string webStatsUrl, ServerGroup serverGroup)
{
if (name == null) throw new ArgumentNullException(nameof(name));
if (webStatsUrl == null) throw new ArgumentNullExc... |
de39728aedbd166923b8671274a97f962278788d | C# | jpginc/JPGNote | /ConsoleApp1/Menus/ManageableCreatable.cs | 2.59375 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
namespace ConsoleApp1.BuiltInActions
{
internal class ManageableCreatable : IActionProvider
{
private readonly IManagerAndActionProvider _manager;
public ManageableCreatable(IManagerAndActionProvider manager)
{
... |
67f40a89fad360aa0c15d512accd068600c910e7 | C# | luizgsp/ImpressaoPDF | /GeracaoColetasPDF/Entities/Items.cs | 2.515625 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace GeracaoColetasPDF.Entities
{
class Items
{
public int ItemSequel { get; set; }
public string ItemCode { get; set; }
public string Description { get; set; }
... |
93843cf89eba3c575c2a1927e2179a84cc509b6a | C# | evoltafreak/MusterAg.Monitoring.Client | /Severity/SeverityRepository.cs | 2.890625 | 3 | using System;
using System.Collections.Generic;
using MusterAg.Monitoring.Client.Model;
using MySql.Data.MySqlClient;
namespace MusterAg.Monitoring.Client.Repository
{
public class SeverityRepository : BaseRepository<Severity>
{
public SeverityRepository(string connectionString)
{
... |
c823daf74ac30ed6a40a3a21b82cda05725d11c6 | C# | J-luoye/HuilyFx | /Common/Utility/Polygon.cs | 3.4375 | 3 | using System.Collections.Generic;
using System.Drawing;
namespace Common.Utility
{
/// <summary>
/// 判断多边形是顺时针还是逆时针的方法
/// </summary>
public class Polygon
{
#region CalculateClockDirection
/// <summary>
/// 判断多边形是顺时针还是逆时针.
/// </summary>
/// <param nam... |
c5057e40fdcf79cf8fdfed37f7936f01262c0ea9 | C# | mgulsoy/nuve | /nuve/Distance/HammingDistance.cs | 3.390625 | 3 | using System;
namespace Nuve.Distance
{
/// <summary>
/// Manhattan distance ile aynı şey bu bağlamda
/// Zira farklı her iki harf arasındaki uzaklığı aynı kabul ediyoruz.
/// </summary>
internal class HammingDistance : IDistance
{
public double Measure(string s1, string s2)
... |
b686b1e6787d5a64997d4ccf8d83db070f1b2a95 | C# | LiboBearChen/SimpleWebBrowser | /Form1.cs | 2.765625 | 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 SimpleWebBrowser
{
public partial class Form1 : Form
{
public Form1()
... |
1ffb43a69cad62811909babb459487dfabff5a80 | C# | iomeone/Ajcek_manufakturalibraries | /Manufaktura.Music/Model/Step.cs | 3.109375 | 3 | /*
* Copyright 2018 Manufaktura Programów Jacek Salamon http://musicengravingcontrols.com/
* MIT LICENCE
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without... |
ef353898bb6112896ea6865f9033b349de248c13 | C# | zhoufengzd/DotNet | /Zen.Lib/Utilities/App.Proc/ResourceLoader.cs | 2.640625 | 3 | using System.IO;
using System.Reflection;
using Zen.Utilities.Generics;
namespace Zen.Utilities.Proc
{
public sealed class ResourceLoader
{
public ResourceLoader()
: this(Assembly.GetCallingAssembly())
{
}
/// <summary>
/// Assembly that contains the reque... |
b1a8c56e9025850b7e1ff15a78a99cbe74039c16 | C# | KentJP/DroneShop-WeFly4You | /Droneshop.Data/Repositories/ManufacturerRepository.cs | 2.53125 | 3 | using System.Collections.Generic;
using System.Linq;
using Droneshop.Core.DomainService;
using Droneshop.Core.Entity;
using Microsoft.EntityFrameworkCore;
namespace Droneshop.Data.Repositories
{
public class ManufacturerRepository : IManufacturerRepository
{
private readonly DroneShopContext _ctx;
... |
a2b17f92e8e046db14009c1b8ac01fd21a217ef4 | C# | nlaracuente/SpaceCrafter | /Scripts/Tiles/PowerTile.cs | 2.71875 | 3 | using UnityEngine;
/// <summary>
/// Requires to be powered ON by a laser to active the win tile
/// </summary>
[RequireComponent(typeof(Collider2D), typeof(SpriteRenderer))]
public class PowerTile : MonoBehaviour, ILaserTarget
{
[SerializeField, Tooltip("Sprite for when the tile is active")]
Sprite m_onSprit... |
1f44efbc7bebef6e07228e7e7da302f5451a4dd0 | C# | morenocles/FeedbackService | /UnitTests/FeedbackService.UnitTests.API/FacadeTests/OrderFacadeTests.cs | 2.546875 | 3 | using FeedbackService.DataAccess.Models;
using FeedbackService.Facade;
using FeedbackService.UnitTests.Fixture;
using Moq;
using System;
using System.Collections.Generic;
using System.Threading;
using Xunit;
namespace FeedbackService.UnitTests.FacadeTests
{
public class OrderFacadeTests : IClassFixture<DataFixtur... |
80382a60d04c7ee54871a4c8214bc189aa533236 | C# | MazieroMarco/MailStorage | /Projet/MailStorage/MailStorage/MailStorage/LoginWindow.cs | 2.671875 | 3 | /// ETML
/// Author : Marco Maziero
/// Date : 10.05.2017
/// Description : Login window, IMAP connect and saves user
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Net.Mail;
using Syste... |
a936b42f39e24e3dac87cb5c54ca2c9ec3615ce0 | C# | miollo/Barbecue | /Data/Repositories/RepositoryBase.cs | 3.453125 | 3 | using BarbecueSpace.Data.Repositories.Interfaces;
using Microsoft.EntityFrameworkCore;
using System.Collections.Generic;
using System.Linq;
namespace BarbecueSpace.Data.Repositories
{
/// <summary>
/// Implementação do repositório base que é herdado pelos outros repositórios
/// </summary>
/// <typepa... |
b53d3236d48025f5bbce8541c5cede6d868bf613 | C# | EmORz/SULS | /Apps/P/P.Data/Models/Package.cs | 2.625 | 3 | using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
namespace P.Data.Models
{
public class Package
{
public Package()
{
this.Id = Guid.NewGuid().ToString();
}
public string Id { get; set; }
[Required]
[MaxL... |
ad0732d820b1732296851813c1b188a42fd691e4 | C# | aevitas/advent | /2020/Advent/Day9.cs | 3.4375 | 3 | using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
namespace Advent
{
internal static class Day9
{
public static void PartOne()
{
using var sr = new StreamReader("Day9.txt");
long[] xmas = sr.ReadToEnd().Split(Environment.NewLine).Select... |
779eda67bc4bcb28afa7c8c7a2866809b67d6a91 | C# | carlplaylab/CardGameJam2016 | /CardGame/Assets/Game/Scripts/UI/NumberIncrementText.cs | 2.578125 | 3 | using UnityEngine;
using UnityEngine.UI;
using System.Collections;
using System;
public class NumberIncrementText : MonoBehaviour
{
[SerializeField] private Text text;
[SerializeField] private float incrementTime = 1;
[SerializeField] private float delayTime = 0;
private int amount = 0;
private int currentA... |
003c725f46ac884d566627aa4e1f994968fe211a | C# | jacksjm/csharp-senac-2019.0520.001 | /View/Funcionario.cs | 2.765625 | 3 | using System;
using Models;
using Controllers;
namespace View {
public class FuncionarioView {
public static void GetFuncionarios(){
FuncionarioController.AddFuncionario(1, "Jackson", "00100200304");
FuncionarioController.AddFuncionario(2, "João", "00200300405");
Funcion... |
0977257a1a443c88d3bce3a8ae70b61bd69e70fd | C# | slowsigma/Nysa | /Nysa.CodeAnalysis/Text/Parsing/GrammarBuilder.cs | 2.84375 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Nysa.Text.Parsing;
public class GrammarBuilder
{
// worker class
private class RuleStart : IGrammarBuildStart, IGrammarBuildContinue
{
private Action<String[]> _Add;
... |
c309c8b444a05d77b791deb16abd78c933335b84 | C# | wk-j/fizz-buzz | /project/Hash/Program.cs | 2.578125 | 3 | using System;
namespace Hash
{
class Program
{
static void Main(string[] args)
{
var h = "Hello";
Console.WriteLine(h.GetHashCode());
Console.WriteLine(100.GetHashCode());
}
}
}
|
ec044d08bba4cd6751fbd6f0825fb9278e795e25 | C# | DF-nsk/Summary-repository | /Calc/Calc/Form1.cs | 2.921875 | 3 | using System;
using System.Windows.Forms;
//Программа калькулятор. В этой версии нет проверки вводимых символов в окно TextBox
//Если ввести буквы, будет ошибка. В ближайщем будущем исправлю.
namespace Calc
{
public partial class Form1 : Form
{
String znak = string.Empty; //знак арифметической опера... |
95a37c69a1058a17b1f238b3f26f1fdf892fe956 | C# | dotnet/runtime | /src/libraries/System.Private.Xml/tests/XmlReader/ReadContentAs/ReadAsUriTests.cs | 2.609375 | 3 | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
using Xunit;
namespace System.Xml.XmlReaderTests
{
public class UriTests
{
[Fact]
public static void ReadContentAsTypeOfUri1()
{
var read... |
b149416ba1d041072264416d6dfab4d21f575ca1 | C# | KDani-99/doc-assistant | /DocAssistantWebApi.Tests/Models/AssistantTests.cs | 2.53125 | 3 | using DocAssistant_Common.Models;
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace DocAssistantWebApi.Tests.Models
{
[TestClass]
public class AssistantTests
{
[TestMethod]
public void CompareObjects_ShouldEqual()
{
// Arrange
var assistant = new... |
4fd8893234564324d6cbb40195614aabcb8b72f5 | C# | Duke02/Notrosoft_Accel | /Notrosoft_Accel.Backend/Statistics/MeanStatistic.cs | 3.390625 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using Notrosoft_Accel.Infrastructure;
namespace Notrosoft_Accel.Backend.Statistics
{
/// <summary>
/// Calculates the mathematical mean.
/// </summary>
public class MeanStatistic : IStatistic
{
/// <summary>
///... |
7a65c52752806aa517d523445c4fe2fe815904fa | C# | MCombs-92/PurchaseRequestModel | /PurchaseRequest/Vendor.cs | 2.890625 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PurchaseRequest {
class Vendor {
static int Counter { get; set; } = 0;
public int Id { get; set; }
public string Code { get; set; }
public string Name { get; set; }
public List<Pr... |
03e6411d2e5f4a682ab529f01a77cb4000066012 | C# | avlhitech256/Price | /Client/PriceList/Domain/Service/Precision/Implementation/PrecisionService.cs | 2.796875 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using Common.Data.Notifier;
namespace Domain.Service.Precision.Implementation
{
public class PrecisionService : Notifier, IPrecisionService
{
#region Members
private string format;
private int precision;
privat... |
e253f1bb728902987ef368752228bd8f9f237d61 | C# | BioWareRu/BioEngine.Core | /src/BioEngine.Core/Entities/BaseEntity.cs | 2.65625 | 3 | using System;
using System.ComponentModel.DataAnnotations;
using BioEngine.Core.Abstractions;
namespace BioEngine.Core.Entities
{
#pragma warning disable CS8618 // Non-nullable field is uninitialized.
public abstract class BaseEntity : IBioEntity
{
[Key] public virtual Guid Id { get; set; } = Guid.Emp... |
679f67820b375c565f89c6a2877de8705fd28192 | C# | shendongnian/download4 | /latest_version_download2/129568-25828620-73454994-2.cs | 2.625 | 3 | private string _text { get; set; }
public string Text
{
get { return _text; }
set
{
_text = value;
if(_text.Length > 5)
// Enable button here
// and command does not enable Buttons they are basically report the clicks eve... |
49a83c28e11ec81134341c2e7d78cd6da41f807d | C# | EdeGarcia/Sistema-De-Registro-Academico | /General/GUI/RolesEdicion.cs | 2.578125 | 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 General.GUI
{
public partial class RolesEdicion : Form
{
private void Procesar... |
e78a60526bbfbb0c4d1cea4fbbb3a4ea41677dae | C# | skorae/SoftUni-kdinev | /C#Fundamentals 3.0 September 2018/OOP Advanced/ReflectionAndAttributes/P01_HarvestingFields/HarvestingFieldsTest.cs | 3.53125 | 4 | namespace P01_HarvestingFields
{
using System;
using System.Linq;
using System.Reflection;
using System.Text;
public class HarvestingFieldsTest
{
public static void Main()
{
string command = Console.ReadLine();
var fields = typeof(HarvestingFields).GetFi... |
731691c736941466818ab9a8de2537a1adabfba7 | C# | Revature-Cinephiliacs/MoviesRepo | /Logic/IMovieLogic.cs | 2.84375 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Model;
using Repository.Models;
namespace Logic
{
public interface IMovieLogic
{
/// <summary>
/// Returns detailed information for the specified movieid. Returns
/... |
3fbe03b1365282f8f004aa93278804914a921c35 | C# | AmiralBl3ndic/Zombeat-Office | /Zombeat-Office/Assets/Scripts/LevelManager.cs | 2.53125 | 3 | using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class LevelManager : MonoBehaviour {
public int levelID = 0;
public AudioClip audioclip;
void Start() { }
// Update is called once per frame
void Update() { }
pr... |
c5a9e73be9a4c672671af1ebf21ebc05a0280b83 | C# | tassoskonst/Csharp-Projects | /MathQuiz/APALLAKTIKIERGASIA2/Form1.cs | 2.703125 | 3 | using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace APALLAKTIKIERGASIA2
{
public partial class Form1 : Form
... |
184a8c244195673baf805cd2d679be78fb0411c7 | C# | o-todorov/SoftUni | /C# OOP/Exercises/07.Solid/07.01.Logger/Readers/TextFileReader.cs | 3.265625 | 3 | using System;
using System.IO;
namespace Solid.Readers
{
class TextFileReader:IReader
{
private string[] lines;
private int position;
public TextFileReader(string path = "log.txt")
{
RearLines(path);
}
public string ReadLine()
{
i... |
deeb5dc8dd3ed38d11f866cad7a97ad0f1e7c083 | C# | shahbazGamedev/GlenGower | /Assets/Scripts/Puzzle/PuzzleBoard/PuzzleGrid.cs | 2.640625 | 3 | using UnityEngine;
using System;
using System.Collections;
public struct GridBoundaries
{
public static float upperXBoundary;
public static float lowerXBoundary;
public static float lowerYBoundary;
}
public enum PuzzleGridDirections
{
NEXT_COLUMN_RIGHT,
PREVIOUS_COLUMN_LEFT,
NEXT_ROW_UP,
... |
3cf444ea565842c0fcdaae1f97ee18473408a184 | C# | JorenSaey/Groep1WindowsPhone | /PackingListApp/PackingListApp/Models/ItemRepository.cs | 2.5625 | 3 | using Microsoft.WindowsAzure.MobileServices;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PackingListApp.Models
{
public class ItemRepository
{
private static MobileServiceCollection<Item, Item> items;
private sta... |
e78446856d71d04277189c8634dd2a20f5db82d2 | C# | Milica-Kostic/ASP.NET_Projects | /BookingApp/BookingApp/Controllers/Api/StaysController.cs | 2.6875 | 3 | using AutoMapper;
using BookingApp.Dtos;
using BookingApp.Models;
using BookingApp.ViewModels;
using System;
using System.Collections.Generic;
using System.Data.Entity;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;
namespace BookingApp.Controllers.Api
{
public class StaysContr... |
12478d600568866d06e2768e85cda07289661dfa | C# | huzaifa7/CheckoutCodeTest | /PaymentGatewayApi/Mapper/BankPaymentMapper.cs | 2.640625 | 3 | using System.Text;
using PaymentGatewayApi.Api.Dto;
using PaymentGatewayApi.Model;
namespace PaymentGatewayApi.Mapper
{
public class BankPaymentMapper : IBankPaymentMapper
{
public BankPaymentRequest MapRequest(PaymentRequest paymentRequest)
{
return new BankPaymentReques... |
daaa0b97b4b50d3ea25fa42ea2c01c3175e1eda1 | C# | dotnet/runtime | /src/libraries/System.Speech/src/Synthesis/InstalledVoice.cs | 2.546875 | 3 | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
using System.Collections.Generic;
using System.Diagnostics;
using System.Globalization;
using System.Speech.Internal;
using System.Speech.Internal.Synthesis;
namespace System.Speech... |
fd82778ad23e50a49856a7350ed86fc6e79bcad8 | C# | Primalpat-/LycanTally | /Old Projects/LycanTally.Core/Threads/ThreadParser.cs | 2.953125 | 3 | using LycanTally.Core.Contexts;
using LycanTally.Core.Entities;
using System;
using System.Collections;
using System.Xml.Linq;
namespace LycanTally.Core.Threads
{
public class ThreadParser
{
private readonly ILycanTallyContext Db;
public ThreadParser(ILycanTallyContext db)
{
... |
7518717fac5cf8dadc02c31e740b56efb495d212 | C# | joshbenjamin/Mix_and_Game_Jam_2020 | /Assets/Scripts/TextController.cs | 2.65625 | 3 | using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
using TMPro;
public class TextController : MonoBehaviour
{
public TMP_Text text;
private int ourGoals = 0;
private int theirGoals = 0;
private void Start()
{
SetScore();
}
public... |
decba8dc50442c4cbf854336f862e4e9c4bae990 | C# | JanisIndrans/Alex | /Program.cs | 3.1875 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Alex.Models;
namespace Alex
{
class Program
{
static void Main(string[] args)
{
// Defining variables
int value = 10;
int amountOfMobs =... |
56b180ee7239846932d0588853a8cc558dd24077 | C# | lamemmv/OnlineSolution | /OS.Web/OS.RSS/Services/RSSFeeds.cs | 2.703125 | 3 | using OS.RSS.Models;
using System;
using System.Collections.Generic;
using System.Xml.Linq;
using System.Linq;
namespace OS.RSS.Services
{
public static class RSSFeeds
{
public static IEnumerable<FeedItem> GetFeeds()
{
string RSSFeedUrl = @"http://sxp.microsoft.com/stream/item?chan... |
b5e6b7edad5d63cbbbe4fec7f5316fd608505297 | C# | MALKAKER/dotNet_step1 | /BE1/Nanny.cs | 2.90625 | 3 | using System;
using System.Collections.Generic;
using System.Text;
namespace BE
{
public class Nanny : Person
{
#region Fields
//Private Fields:
private int expYearsP;
private int maxChildrenP;
private int minAgeP;
private int maxAgeP;
private decimal co... |
a292a1ce39637fd3cc295c7721f795471d9d8101 | C# | jim-conner/QuikTrippinWithDumbledore | /QuikTrippinWithDumbledore/Employee/EmployeeRepository.cs | 2.546875 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace QuikTrippinWithDumbledore.Employee
{
class EmployeeRepository
{
static List<DistrictManager> _districtManagers = new List<DistrictManager>()
{
new DistrictM... |
2684fa0acde9954ded9e1699112382527b8340db | C# | chenjiong1972/CyControl | /UnvaryingSagacity.Core/AxMainConsole.cs | 2.578125 | 3 | using System;
using System.Collections.Generic;
using System.Text;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.Drawing.Imaging;
using System.Windows.Forms;
namespace UnvaryingSagacity.Core
{
public class AxMainConsole:UserControl
{
public delegate void ItemEventHandle(obje... |
ef85a2196fa057b3d8fafa30bdb5bf09b8e74385 | C# | jackshea/leetcode | /LeetCode/Problems/Medium/P0095_UniqueBinarySearchTreesII.cs | 3.328125 | 3 | using System.Collections.Generic;
using LeetCode.Common;
namespace LeetCode.Problems.Medium;
/// 不同的二叉搜索树 II
/// https://leetcode-cn.com/problems/unique-binary-search-trees-ii/
public class P0095_UniqueBinarySearchTreesII
{
public IList<TreeNode> GenerateTrees(int n)
{
if (n <= 0) return new List<Tre... |
64b6e10c86fba32b61ae1731a2093ac921e44156 | C# | Software-Maniacs/FlightsManager-Repo | /FlightsManager/Models/UserViewModels/CreateUserViewModel.cs | 2.8125 | 3 | using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Threading.Tasks;
namespace FlightsManager.Models.UserViewModels
{
/// <summary>
/// Viewmodel through which a user is created.
/// </summary>
public class CreateUserViewModel
... |
2ebc426585267245bead46fa66c0c7385f5fa6c5 | C# | Zulfia73/forSimbirsoft | /С#.Salakhutdinova/Исходный код/Dictionary.cs | 2.828125 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.IO;
using System.Windows.Forms;
namespace TestTaskSalakhutdinova
{
class Dictionary
{
public string DicOpen(string place)
{
FileStream dicfile = File.Ope... |
403e4b845124b139dd48e62697b9ca812e2d6b5d | C# | heomap1405/NABS_AssessmentTest | /test1_palindrome.cs | 3.828125 | 4 | using System;
public class Program
{
public static void Main()
{
var str = "1-2-3-4-5-4-3-2-1";
var str_lth = str.Length;
var s = 0;
for(var i = 0; i < str_lth/2; i++){
if (str[i] != str[str_lth - 1 - i]){
s+=1;
}
... |
183248c968690f3f29accaf88aeb1694224e1d6a | C# | hoangvietnguyen99/ecsystem | /ECSystem/DTO/KhachHangDTO.cs | 2.546875 | 3 | using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ECSystem.DTO
{
public class KhachHangDTO
{
private string maKH;
private string tenKH;
private string email;
private string diaChi;... |
b5b96d2b8bbfbef810023f2a7dd524c1393881a3 | C# | vesy53/SoftUni | /Programming Basics - C#/Exams/Programming Basics Exam - 25 June 2017/p02WorldSwimmingRecord/Program.cs | 3.765625 | 4 | using System;
namespace p02WorldSwimmingRecord
{
class Program
{
static void Main(string[] args)
{
double recordInSec = double.Parse(Console.ReadLine());
double recordInM = double.Parse(Console.ReadLine());
double timeInSec1M = double.Parse(Console.ReadLine(... |
9af3714d9cc97e1e6288029f51a3e9da39c06db7 | C# | xx5ko/CSharp | /CountOfCapitalLettersinArray/Program.cs | 3.421875 | 3 |
using System;
using System.Linq;
namespace CountOfCapitalLettersinArray
{
class MainClass
{
public static void Main(string[] args)
{
string[] arr = Console.ReadLine().Split(' ').ToArray();
int counter = 0;
foreach (var strings in arr)
{
if (strings.Length == 1 && strings[0] >= 65 && strings[0] ... |
6f0614998ffd48a27d0a499131f3f98b422a159b | C# | AndreasKarg/soundthesizer-converter | /SoundthesizerConverterBackend/SoundSet.cs | 2.84375 | 3 | using System.Collections.Generic;
namespace SoundthesizerConverterBackend
{
public interface ISoundSet
{
string Name { get; }
IReadOnlyCollection<ISound> Sounds { get; }
}
public class SoundSet : ISoundSet
{
private readonly IReadOnlyCollection<ISound> _sounds;
public string Name { get; pr... |
e8bbcd9c91caa4c8f52ca375c48bf061b6c9e40d | C# | EliasMartinezFunes/E-Pets | /Mascotas.App/Mascotas.App.Console/Program.cs | 2.609375 | 3 | using System;
using Mascota.App.Dominio.Entidades;
using Mascota.App.Persistencia.AppRepositorios;
using Mascota.App.Persistencia;
using System.Linq;
namespace Mascotas.App.Console
{
class Program
{
public static IRepositorioMascota _repoMascota= new RepositorioMascota(new Mascota.App.Persistencia.Ap... |
e76919c4efe76850bb5434bd0e34fa9403a63067 | C# | vilfrack/Efrain | /Restaurante/LoginForm.cs | 2.625 | 3 | using Restaurante.Utilidades;
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 Restaurante
{
public partial class LoginForm : Form
{
... |
e5a8b3ef9fe4504b42521c3036b66ceb11587f10 | C# | ivaylo-R/CSharp-Fundamentals-May-2020 | /04.MethodsLab/04.MethodsLab/Program.cs | 3.890625 | 4 | using System;
namespace _04.MethodsLab
{
class Program
{
static void Main(string[] args)
{
int n = int.Parse(Console.ReadLine());
PrintNum(n);
}
private static void PrintNum(int x)
{
if (x > 0)
{
Console.W... |
b6291ed4cb01dab43232c5ac71e9aa89ae00f610 | C# | mustafa-kus/LastGame-Before-Co-Project | /LastGame-Before Co-Project/PlayerManager.cs | 3.140625 | 3 | using System;
using System.Collections.Generic;
using System.Text;
namespace LastGame_Before_Co_Project
{
class PlayerManager
{
public void Add(Player player)
{
if (CheckPersonalId(player))
{
Console.WriteLine("Player Registered:" + player.Name);
... |
347187493fc3497458d9c3c851c952b52f4aa330 | C# | darmangerd/pong-game | /PongGame/Ball.cs | 3.4375 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PongGame
{
public class Ball
{
#region déclaration des variables
/// <summary>
/// Vitesse de déplacement de la balle en vertical x
/// </summary>
... |
321029394b75bb25b723c8916220b8caa4509194 | C# | ZAYEC77/HCI8 | /Common/ClientManager.cs | 3 | 3 | using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Net;
using System.Net.Sockets;
using System.Threading;
using System.IO;
using System.Windows.Forms;
namespace Common
{
public class ClientManager
{
public string IP { get; set; }
public int Port ... |
acfdd6f3b77a56631c8bc011768d0bf9bd0c3480 | C# | Scagneti/Eleven50.NET | /03_DefiningClasses_2/Weather.cs | 2.78125 | 3 | using System;
namespace _03_DefiningClasses_2
{
public enum WindDirection
{
North = 1,
Northeast,
East,
Southeast,
South,
Southwest,
West,
Northwest
}
public class Weather
{
public int Id { get; set; }
public float Temperature { get; set; }
public WindDirection WindDirection { get; s... |
0456711438b3cc9db60b251ccacd3d5082b033d3 | C# | crennicke/Dungeoneering | /Dungeoneering/Assets/Lore_Page_Interaction.cs | 2.6875 | 3 | using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class Lore_Page_Interaction : MonoBehaviour
{
[SerializeField] private Image customImage;
public GameObject globalVars;
public string page_num = "1";
Vector3 posOffset = new Vector3();
Vec... |
b704a1fc374cca66c43690eee981dd3086288305 | C# | funkysandman/funkyCams | /ExampleInceptionInference/Detection.cs | 2.625 | 3 | using System;
using System.Collections.Generic;
using System.Drawing;
using System.Drawing.Imaging;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using TensorFlow;
namespace TensorFlowDetectorx
{
public class Detection
{
TFSession session;
TFGraph graph;
... |
e4e68baad1453804ecdf1b71f8e1348337bb84ce | C# | Vali0/Telerik-Academy-Courses | /CSharp - 1/Homeworks/ConsoleInputOutput/Task02CirclePerimeterArea/Task02CirclePerimeterArea.cs | 3.75 | 4 | using System;
class Task02CirclePerimeterArea
{
static void Main(string[] args)
{
int radius;
Console.WriteLine("Enter the radius of the circle: ");
radius = int.Parse(Console.ReadLine());
Console.WriteLine("Circle perimeter is : " + 2 * Math.PI * radius); // Calculating perime... |
d8362cd2616ef47aa9efee529ab7ac2c0341509b | C# | trentdm/Dash | /src/Dash/Api/Utils/ListEntrySerializer.cs | 3.03125 | 3 | using System;
using System.Reflection;
using Google.GData.Spreadsheets;
namespace Dash.Api.Utils
{
public static class ListEntrySerializer
{
public static T Deserialize<T>(this ListEntry row) where T : new()
{
var result = new T();
foreach (var prop in typeof(T).GetPro... |
863a2cb177e655830f4a1b7b0dabdda56a4a1059 | C# | danshaub/GameOfLifeExtendedEdition | /Assets/Scripts/DemoCell2.cs | 2.703125 | 3 | /*
Name: Dan Haub
Student ID#: 2315346
Chapman Email: haub@chapman.edu
Course Number and Section: CPSC 236-01
Assignment: Final (Game of Life Extended Edition)
*/
using UnityEngine;
public class DemoCell2 : MonoBehaviour
{
bool alive = false;
private SpriteRenderer cellSprite;
private DemoBoard demo... |
a9f19924e9b1b2c7a240a024e650259c9873b8fe | C# | StanisInt/SoftUniHomeworks | /5. OOP/Exam/Problem-1-Estates/Data/Estates/Garage.cs | 3.46875 | 3 | namespace Estates.Data.Estates
{
using System;
using System.Text;
using Abstract;
using Interfaces;
public class Garage : Estate, IGarage
{
private int width;
private int height;
public Garage(
string name = null,
double area = 0,
... |