solulubeta
Sign in
NeetCode 150 / Trees
07.10 · Problem

Count Good Nodes in Binary Tree

Medium DFS carrying the path maximum 1 video LC 1448 Pro

This problem is part of solulu Pro

A node is good if no node on the path from the root to it has a greater value. Return the number of good nodes. (The root is always good.)

Lifetime ₹1,999 ₹999 · Launch offer
Mark this problem as solved when you are finished.

Item 55 of 150 · updated 2026-10-12