Shil and LIS
CodeChefOpen on judge ↗
Shil has an array of N integers A1 , A2....AN.He can insert an element 1 ≤ X ≤ K between any two adjacent numbers or at the start or at end of array.He wants to find out total number of ways to insert an element such that length of longest strictly increasing sub-sequence of the array increases by 1.Two ways are considered different if position of inserted element is different or value of the inse
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start