Programming Concepts — Algorithm
An algorithm is a step-by-step set of instructions designed to solve a specific problem or perform a task. Algorithms form the foundation of computer programs.
// Example: Algorithm to find the sum of two numbers
function sum(a, b) {
return a + b;
}
console.log(sum(5, 3)); // Output: 8