Showing articles with Shibam Dhar. Show all articles
Java is an object-oriented programming language, which offer a neat modular structure thereby making it easier to solve complex problems. Its modular nature helps programmers to write reusable code and also enhances the development process.
A struct type is a value type that is typically used to encapsulate small groups of related variables such as the coordinates of rectangle and all.They are basically for light weighted objects. Unlike class, structs in C# are value type than reference type. It is useful if you have data that is not intended to be modified after creation of struct.
Inheritance is pretty much a crucial concepts for all the OOP languages and it is so for C Sharp. Inheritance allows us to define a class baes on another class. Basically inheriting features in one class from another.
Most of the C# operators can be overloaded which means they can be redefined for custom actions. To do various operations by a single operator, it can be done with the help of operator overloading.
In C# static is something which can not be instantiated. It is a modifier which can be applicable to many things such as classes, methods, variables and constructors. When a member is declared static, it can be accessed with the name of its class directly.
C# Constructor and Properties
C# provides numerus built-n classes to store and manipulate data. One of such classes is the Array Class.
Everything in C# having attributes and properties includes classes and methods. A class is a data type. It stores objects of similar types. It can have fields, methods, constructors, etc. The class creates an object. Each object has its own characteristics. These characteristics are known as properties.