The following code example demonstrates Rotating an Array in C#. In fact, array rotation is a programming exercise that helps you improve programming logic. Moreover, it also requires students to develop critical thinking and to find think about logic to solve a problem in an efficient manner. In other words, the application logic needs to …
JSTL Tags for Condition and Loop
In this article, I will discuss the examples of JSTL Tags for Condition and Loop. In general JSP tag Library contains <c:if>, and <c:forEach> tags for checking conditions, and loops respectively. Syntax of <c:if> Tag <c:if test=””, var=””, scope=””></c:if> Basically, the test attribute specifies the condition. While the var attribute stores the result of the …
Standard Template Library in C++
Basically, Standard Template Library (STL) in C++ is a library of data structures. Hence, by using STL, we need not bother about implementing the commonly used data structures. Instead, we can focus on application-specific tasks. Therefore, Standard Template Library in C++ supports the reusability of the code. Another benefit that we get by using STL …
Using Arrays in Java
This article explains Using Arrays in Java. Basically, an array is a data type that contains multiple elements of the same data type. Declaring Arrays in Java The following code shows that how to declare arrays in Java. Syntax: Since, arrays are dynamically, allocated in Java, we need to use the new operator, as shown …
Compute and Display Area of a Circle in Java
The following code example shows how to Compute and Display Area of a Circle in Java. Apart from being a simple program, it lets you learn many useful basic concepts of Java programming language when you have just started learning. The following section describes some of the important points. Accepting Input from User In order …
C Program to Find Factorial of a Number
The following code example demonstrates a C Program to Find Factorial of a Number. As can be seen, the program contains both recursive and non-recursive functions for computing the factorials. Recursive Functions Basically, a recursive function is a function that calls itself. In other words, a recursive function keeps on calling itself until a certain …
Generic IList Interface and its Implementation in C#
In this article, I will explain Generic IList Interface and its Implementation in C#. In fact, the .NET Framework library provides a Collections framework that contains the implementation of commonly used data structures. Further, there are generic as well as non-generic collections that exist in the library. While non-generic collections can work on any type. …
Recursive Binary search in C#
The following code example demonstrates the Recursive Binary search in C#. Basically, searching is a very important algorithm in computer science. In fact, almost every application requires the use of searching. Hence, an efficient implementation of the searching algorithm can have substantial improvement in the overall performance of the applications. Searching Techniques In short, there …
C# Practice Questions
The following C# Practice Questions will help you learn the C# language. C# Practice Questions – Basic Programs Understanding the compilation and running of programs on VS.NET 2019. Write a program that displays following: “A simple C# Program.” Create a program that converts temperature specified in Celsius into Fahrenheit.Write a program to compute area of …
Java Practice Exercise
This Java Practice Exercise contains programming problems on core Java. Further Reading 30+ Basic Java Programs Java Code Examples The following Java Practice Exercise will help you learn the Java Programming Language. Create a Java application that computes and displays the area of a circle. Demonstrate how typecasting & conversions take place in Java. Write …