Coding Best Practices
Welcome to Performance & Best Practices section of C# Corner. In this section, you will find various Performance & Best Practices related source code samples, articles, tutorials, and tips.

RECENT POSTS

  • Best Practices Of Writing C# Code

    Anyone can write code with a few months of programming experience. But some developers know the coding standard and naming convention but not everyone follows the best practices
  • Seven Tips To Increase Your Productivity

    Writing a robust code and finishing the project in a short time are the main characteristics of a professional job, so every developer should focus on his/her productivity to create efficient code in
  • How To Implement TDD In C# Using NUnit Testing With NInject DI

    How to implement TDD (Test driven development) in c# (Csharp) using Nunit testing with NInject DI?
  • Defensive Programming - Let Type Checking Work For You

    Since I have been a speaker and a teacher, I have always stressed the importance of practicing proper object-oriented programming (OOP) techniques. If you don’t practice OOP, no matter what language y
  • Five Easy Rules For Your Source Control Repository

    I have been using source control programs for a very long time. I believe the first one was Visual Source Safe (don’t laugh, it was a painful experience). Early in my career and throughout I have lear
  • When To Use "Var" As A Type

    It has been quite a long time since "var" was introduced, yet it is still a topic of debate among .net developers.
  • SQL Coding Best Practices

    While executing your procedure, the system will first scan through all system procedures and then user defined procedures. This means that the procedure might take more time for execution thus decreas
  • Beautifying C# Code - Part II

    In this video, how we can beautify\reduce number of lines in your C# Code.
  • Beautifying Your C# Code - Part I

    In this video, how we can beautify\reduce the number of lines in your C# code.
  • Rules To Write Clean And Good Unit Tests

    Unit tests should be fast and run quickly. If they won't, then we won't want to run them frequently.
  • Code Metrics Cyclomatic Complexity

    Let's learn about Code Metrics Cyclomatic Complexity in this write-up.
  • Confessions Of An Angry Programmer

    Recently, after doing the keynote session about code quality at a conference in Denver, I received a comment from one of the attendees. He said my session was “too much angry coder”. After receiving m
  • Best Practices For MVC

    Add a class library project to the solution, named Store.Model. This library is where we ‘ll keep all of our domain objects. Entity Framework will count on them in order to build the database but we a
  • My Workflow Before I Submit Code Changes

    In this article, you will learn about my Workflow before I submit code changes.
  • Effective Application Development

    In this blog I would like to share some of my Application Development methodologies which give some more productivity in development.
  • A Day With A Software Engineer Who Changes Text Labels Only

    This article will explain the way Software Engineers, who never focus on technical learning and remain busy in text label changing only.
  • Validation Response Pattern

    An interface based pattern to return the appropriate business logic validation outcome.
  • How To Learn A New Computer Programming Language

    This article is about learning a new programming language
  • Stop Using VAR Everywhere And Think Before Using Underscore With Private Variable In C#

    When to use underscore(_) or not with the private member variable; why we shouldn't use var everywhere; when must we use 'var'; when can't 'var' be used. Why we need to follow
  • Five Golden Rules For Better Programming

    Five Golden Rules For Better Programming.
  • Functions In Functional Programming Vs Procedural Programming

    In this article, I will show you what a basic function is and the concept of the function, as it is used in functional programming and how procedural (or imperative) languages might take them wrong.
  • Web Application Solution Architecture Naming Conventions

    In this blog, you will be acquainted with Web Application Solution Architecture naming conventions.
  • Bench-marking List vs Dictionary vs HashSet vs SortedSet

    It is always wise to evaluate the performance of datatypes before using it. It will save developer from last minute design change/ code change to address critical issues such as performance / memory.
  • Coding Challenge - Lesson Learned

    Here, I am sharing some note from the coding challenge: NumberStyles, Tuple, Generic Extension Method, Group string from right to left.
  • Why Comments Are Important While Writing Code

    This blog is about why comments are important and how they help to understand the code as well as when and where we should use comments.