GOLANG_INTERVIEW Telegram 377
💡Задача: Нахождение существующего пути

Условие: дается ненаправленный граф, ребра которого представлены в массиве. Между каждой парой узлов в дереве имеется не более одного ребра.

Необходимо определить существует ли корректная дорога между узлом source и destination.

Пример:

Ввод:
n = 3, edges = [[0,1],[1,2],[2,0]], source = 0, destination = 2
Вывод: true
Объяснение: *во вложении

Ввод: n = 6, edges = [[0,1],[0,2],[3,5],[5,4],[4,3]], source = 0, destination = 5
Вывод: false

📌 Решение

Пишите свое решение в комментариях👇

@golang_interview
Please open Telegram to view this post
VIEW IN TELEGRAM
👍6🔥32



tgoop.com/golang_interview/377
Create:
Last Update:

💡Задача: Нахождение существующего пути

Условие: дается ненаправленный граф, ребра которого представлены в массиве. Между каждой парой узлов в дереве имеется не более одного ребра.

Необходимо определить существует ли корректная дорога между узлом source и destination.

Пример:

Ввод:
n = 3, edges = [[0,1],[1,2],[2,0]], source = 0, destination = 2
Вывод: true
Объяснение: *во вложении

Ввод: n = 6, edges = [[0,1],[0,2],[3,5],[5,4],[4,3]], source = 0, destination = 5
Вывод: false

📌 Решение

Пишите свое решение в комментариях👇

@golang_interview

BY Golang вопросы собеседований




Share with your friend now:
tgoop.com/golang_interview/377

View MORE
Open in Telegram


Telegram News

Date: |

Read now Add up to 50 administrators Although some crypto traders have moved toward screaming as a coping mechanism, several mental health experts call this therapy a pseudoscience. The crypto community finds its way to engage in one or the other way and share its feelings with other fellow members. Commenting about the court's concerns about the spread of false information related to the elections, Minister Fachin noted Brazil is "facing circumstances that could put Brazil's democracy at risk." During the meeting, the information technology secretary at the TSE, Julio Valente, put forward a list of requests the court believes will disinformation. Unlimited number of subscribers per channel
from us


Telegram Golang вопросы собеседований
FROM American