 
 Data Structure Data Structure
 Networking Networking
 RDBMS RDBMS
 Operating System Operating System
 Java Java
 MS Excel MS Excel
 iOS iOS
 HTML HTML
 CSS CSS
 Android Android
 Python Python
 C Programming C Programming
 C++ C++
 C# C#
 MongoDB MongoDB
 MySQL MySQL
 Javascript Javascript
 PHP 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
Programming Articles - Page 615 of 3366
 
 
			
			372 Views
This tutorial will discuss how to write a Swift program to perform nCr(r-combination). nCr refers to r- combination. It is used to calculate the possible arrangements where the order of the selection does not matter. Or we can say that nCr is used to select r items from the set of n items where the order of the items does not consider. Formula Following is the formula of nCr nCr = (n!)/(r! * (n - r)!) Below is a demonstration of the same − Suppose we enter the following input. N = 5 R = 3 Following is the ... Read More
 
 
			
			2K+ Views
This tutorial will discuss how to write a Swift program to find the largest among three numbers. Given three numbers now we have to find the largest among the given three numbers. So we will compare all three numbers with each other to find the largest number. Below is a demonstration of the same − Suppose we enter the following input − 39, 87, 12 Following is the desired output − Largest number is 87 Finding largest number using max() function Swift provides an in-built method named as max() function. This function returns the maximum number ... Read More
 
 
			
			5K+ Views
This tutorial will discuss how to write a Swift program to find factorial of a number. A Factorial of a non-negative number is calculated by multiplying the number with every whole number till 1 for example, 6! = 6 x 5 x 4 x 3 x 2 x 1 = 720 which means the factorial of 6 is 720. The general form of factorial is − M! = m x (m - 1) x (m - 2) x (m - 3) …. X 1 Formula Following is the formula of factorial − M! = M * (M - 1)! ... Read More
 
 
			
			927 Views
This tutorial will discuss how to write a swift program to find the surface area and volume of cuboid. A Cuboid is a 3-dimensional solid figure which contains six rectangular faces, eight vertices and twelve edges. It has three dimensions known as length, breadth, and height and if a cuboid has integer edges then the cuboid is the perfect cuboid. The opposite edges of the cuboid are always parallel to each other and the angle formed by all vertices are 90 degrees Surface area of cuboid Surface area of a cuboid is the total space occupied by the cuboid. ... Read More
 
 
			
			657 Views
This tutorial will discuss how to write a swift program to find the area of a parallelogram.A Parallelogram is a quadrilateral that is created using parallel lines.Where the opposite sides are parallel and equal and the opposite angles of the parallelograms are equal. It is of three types - rectangle, square, and rhombus.In a parallelogram, an area is known as the space that is enclosed inside the boundaries or sides of the parallelogram in the two-dimensional plane. Suppose we have a tea try now the area of the parallelogram helps us to find how much paint we required to cover ... Read More
 
 
			
			284 Views
This tutorial will discuss how to write a swift program to find the area of a trapezium.A trapezium is a quadrilateral with at least a pair of opposite parallel sides. The parallel sides are known as the base and the non-parallel sides are known as the legs of the trapezium. The distance between the parallel sides is known as the height of the trapezium.In a trapezium, an area is known as the space that is enclosed inside the boundaries of the trapezium in the two-dimensional plane. Suppose we have a board, now the area of the trapezium helps us to ... Read More
 
 
			
			555 Views
This tutorial will discuss how to write a swift program to find the perimeter of a Rectangle.A rectangle is a 2-dimensional closed shape with four sides in which opposite sides are parallel and equal to each other. It also has four angle with 90 degrees each.The perimeter of the rectangle is used to calculate the boundary of the rectangle. Or we can say that it is the total distance covered by the rectangle’s outer boundary as show in the above diagram. It is the one of the most important formula of the rectangle. Suppose we want to fence our rectangular ... Read More
 
 
			
			660 Views
This tutorial will discuss how to write a swift program to calculate the simple interest and compound interest. Compound Interest The interest applied on the principal and interest together over a certain period of time is known as the compound interest. Or in other words compound interest is known as the interest on interest. It is calculated after calculating amount. Formula Following is the formula of compound interest − Amount(A) = Principal(P)(1 + Rate/100)Time(t)C.I = Amount(A) - Principal(P) Where Principal(P) − Principal amount represents the amount which is initially invested. Rate(R) − Rate represents the interest rate which applied ... Read More
 
 
			
			259 Views
This tutorial will discuss how to write a swift program to check whether the input number is a Neon Number. In a number system, a number whose sum of digits of square of the number is equal to the number is known as neon number. Below is an example of the neon numbers − Let’s see if number 9 is a neon number or not? - The square of 9 is 81 and the sum of 81 is 9 So 9 is a neon number Let’s take another example - 15 The entered number is not a neon number Here, ... Read More
 
 
			
			851 Views
This tutorial will discuss how to write a swift program to calculate compound interest. The interest applied to the principal and interest together over a certain period of time is known as compound interest. In other words, the compound interest is known as the interest on interest. It is calculated after calculating the amount. Formula Following is the formula of compound interest − Amount(A) = Principal(P)(1 + Rate/100)Time(t) C.I = Amount(A) - Principal(P) Where Principal(P) − Principal amount represents the amount that is initially invested. Rate(R) − Rate represents the interest rate, that applied to the principal amount for the ... Read More