What is mistake in my code

code: https://ide.codingblocks.com/s/215312

@spagire4
You’re making the tree incorrectly. Line 40-43
Please see this for correct code https://www.geeksforgeeks.org/maximum-subarray-sum-given-range/

If your doubt is resolved please close it