Skip to content

atique-ahmad-01/problem-solving

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

problem-solving

A collection of problem-solving functions in Go.

Fibonacci Sequence

The Fibonacci sequence is a series of numbers in which each number is the sum of the two preceding ones. This function calculates the Fibonacci sequence up to a given number n and returns the sequence as an array or slice.

Prime Numbers

This function determines whether a given number n is prime or not. A prime number is a natural number greater than 1 that is divisible only by 1 and itself.

Palindrome Check

The palindrome check function determines whether a given string is a palindrome. A palindrome is a word, phrase, number, or other sequence of characters that reads the same forwards and backwards.

Reverse String

The reverse string function reverses a given string without using the built-in reverse function. It swaps the characters from the start and end of the string until the entire string is reversed.

Number Sequence

The number sequence function generates various number sequences based on user input. It currently supports the following types of sequences:

  • Fibonacci Sequence
  • Prime Numbers
  • Palindrome Numbers
  • Square Numbers
  • Cube Numbers

Factorial

The factorial function calculates the factorial of a given number n. The factorial of a non-negative integer n is the product of all positive integers less than or equal to n.

Find Duplicates

The find duplicates function finds and returns any duplicates in a given array or slice. It scans through the elements and identifies any values that occur more than once.

Binary Search

The binary search algorithm searches for a given target value in a sorted array. It repeatedly divides the search interval in half until the target value is found or the interval is empty.

Anagram Check

The anagram check function checks whether two given strings are anagrams. Anagrams are words or phrases formed by rearranging the letters of another word or phrase.

Word Count

The word count function counts the occurrence of each word in a given string and returns the word count as a map. It splits the string into words and counts their frequencies.

Matrix Operations

The matrix operations functions perform basic matrix operations such as matrix addition, multiplication, and transposition. These operations are useful in linear algebra and numerical computations.

About

Self-learning practice repository in Go Lang, featuring beginner-level problem-solving exercises to solidify foundational skills and understanding of Go programming.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages