Welcome To Golang By Example

Menu
  • Home
  • Blog
  • Contact Us
  • Support this website
Menu

Tag: golang

Print all Binary Tree Paths in Go (Golang)

Posted on July 20, 2022July 20, 2022 by admin

Overview The root of a tree is given. The objective is to print all the tree paths starting with the root. Example Output: Program Below is the program for the same Output:…

Detonate the maximum bombs program in Go (Golang)

Posted on July 17, 2022July 17, 2022 by admin

Overview A 2d array  is given where each entry in an  array has three values i- Denotes the x coordinates of the bomb j – Denotes the y  coordinates of the  bomb…

Rotting Oranges Program in Go (Golang)

Posted on July 17, 2022July 17, 2022 by admin

Overview An m*n matrix is given where each entry contains three values 0 – Denotes that entry is empty 1 – Denotes that entry contains fresh orange 2 – Denotes that the…

Count unreachable pair of nodes in an undirected graph in Go (Golang)

Posted on July 15, 2022July 15, 2022 by admin

Overview An integer n is given. There are n  nodes numbered 0 to n-1.  A 2D integer array edges is also given where edges[i] = [ai, bi] means that there is an…

Majority element in an array in Go (Golang)

Posted on June 6, 2022June 6, 2022 by admin

Overview The objective is to find the majority element in a given array. A majority element is an element that occurs more than n/2 times in a given array where n is…

Non-Overlapping intervals program in Go (Golang)

Posted on March 14, 2022March 14, 2022 by admin

Overview An array of intervals is given where intervals[i] = [starti, endi]. We have to find out the minimum number of intervals to remove so that the interval in the intervals array…

Kth Distinct String in an Array Program in Go (Golang)

Posted on March 14, 2022March 14, 2022 by admin

Overview An input string array is given which can have duplicate strings as well. An input number k is also provided. Idea is to find the first kth distinct string in the…

Program for House Robber Problem in Go (Golang)

Posted on March 14, 2022March 14, 2022 by admin

Overview There are a couple of houses in the neighborhood. Each house has some money in it. The houses are represented as an array which each entry in the array denotes the…

Distinct or Unique Permutations of a string or array in Go (Golang)

Posted on March 14, 2022March 14, 2022 by admin

Overview Given an array of integers that can contain duplicate elements, find all distinct permutations only. Example Program Here is the program for the same. Output Note: Check out our Golang Advanced…

Program for the total number of words in a sentence in Go (Golang)

Posted on March 11, 2022March 11, 2022 by admin

Overview Given a sentence find number of words in it. Each word in the sentence only has English letters Example Program Here is the program for the same. Output Note: Check out…

Posts pagination

Previous 1 2 3 … 41 Next
Follow @golangbyexample

Popular Articles

Golang Comprehensive Tutorial Series

All Design Patterns in Go (Golang)

Slice in golang

Variables in Go (Golang) – Complete Guide

OOP: Inheritance in GOLANG complete guide

Using Context Package in GO (Golang) – Complete Guide

All data types in Golang with examples

Understanding time and date in Go (Golang) – Complete Guide

©2025 Welcome To Golang By Example | Design: Newspaperly WordPress Theme