Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Server Side Programming Articles - Page 434 of 2650
329 Views
In this tutorial, we discuss writing a program to check if two of three Boolean variables are true in the Haskell programming language Boolean variables are the type of variable which hold the boolean value true and false. In this tutorial, we see two different ways to implement a program to check if two of the three boolean values are true Program to check if two of the three boolean values are true in an iterative method. Program to check if two of the three boolean values are true in a recursive method. Algorithm steps Declare or ... Read More
1K+ Views
In this tutorial, we discuss writing a program to calculate the sum of the natural numbers in the Haskell programming language. Natural numbers are positive integers starting from 1, 2, 3...N In this tutorial, we see different ways to implement a program to compute the sum of natural numbers. Program to compute the sum of the natural numbers using a mathematical formula. Program to compute the sum of the natural numbers using a recursive function. Program to compute the sum of the natural numbers using the list method/function sum. Algorithm steps Declare or take input the range ... Read More
512 Views
In this tutorial, we discuss writing a program to calculate simple and compound interest in the Haskell programming language In this tutorial, we see Program to compute Simple interest. Program to compute Compound interest. Simple interest is an Interest method for an investment, where interest is defined as I = p*t*r/100, where p is the invested amount, t is the quantity of time in years, and r is the interest rate. (per 100). Example − For an invested amount of 1000(p), t= 2 and r =3 the interest is 60. Compound interest is an Interest method for an ... Read More
407 Views
In this tutorial, we will learn how to print spiral pattern of Numbers using Go programming language. A Spiral pattern of numbers is used to print numbers in spiral pattern on the screen. In this program we will create an array of size n, store numbers in it and use the array to create a matrix in a spiral format. Syntax for initialization; condition; update { statement(s) } func make([]T, len, cap) []T make() function is used to allocate memory of heap for some variables. For eg we can use make() function to allocate memory for ... Read More
666 Views
In this tutorial we will write a Go-lang code to print Reverse pyramid star pattern. We will depict how you can print the reverse pyramid star pattern. ********* ******* ***** *** * How to print a Reverse Pyramid star pattern? A pattern is shown above, and in the pattern, you can clearly see that 2 stars is decreasing with increase in each row. If the total rows are 5, the pattern goes like ... Read More
899 Views
In this tutorial we will write a Go language code to print pyramid star pattern. We will depict how you can print the pyramid star pattern. * * * * * * * * * * * * * * * * * * * * * * * * * How to print a Pyramid star pattern? A pattern is shown above, and in the pattern, you can clearly see that 2 stars is increasing with increase in ... Read More
17K+ Views
In this tutorial we will learn how to convert int type variables to string variables using Golang programming language. A string is defined as the sequence of one or more characters (letters, numbers, or symbols). Computer applications frequently use strings as a data type thus, there is a need to convert strings to numbers or numbers to strings at manny places specially when we are using data entered by the user. Syntax func Itoa(x int) string Itoa() function in go programming language is used to get the string representation of any integer value here it is depicted by ... Read More
885 Views
In this tutorial we will learn how to convert double(float64) type variables to string variables using Golang programming language. Double stands for double precision. In programming languages, a double data-type is used to handle decimal numbers more precisely i.e. using double data type we can store more number of digits after a decimal point with accuracy. String data type is used to store a sequence of characters. It can be in the form of literals or alphabets. The size of string variable is 1 byte or 8 bits. EXAMPLE 1: GO LANGUAGE CODE TO CONVERT DOUBLE TYPE ... Read More
3K+ Views
In this tutorial we will learn how to convert double type variables to integer variables using Golang programming language. Double stands for double precision. In programming languages, a double data-type is used to handle decimal numbers more precisely i.e. using double data type we can store more number of digits after a decimal point with accuracy EXAMPLE 1: GO LANGUAGE CODE TO CONVERT DOUBLE TYPE VARIABLES TO INT: Syntax fmt.Println(int(b)) Int(x) To convert a float type input ... Read More
2K+ Views
In this tutorial, you will learn what is a question mark in the Swift language, how to use it, and what it is used for. What does the question mark indicate? This question mark indicates that a variable might contain a nil value or some value of type declared with the variable. Before learning what a question mark is, let's understand what are optionals in Swift. Optionals When you create a variable in the Swift language, either it can contain an initial value or it might be holding nothing at the initial point. In that ... Read More