[Rust] LIS
Partition_pointis supported since 1.52.0 in Rust. But it is not yet supported on leetcode. As a work around, we can manually implement the binary search partiti
`Partition_point`is supported since 1.52.0 in Rust. But it is not yet supported on leetcode. As a work around, we can manually implement the binary search partition.\n``` rust\nimpl Solution {\n    pub fn k_increasing(arr: Vec<i32>, k: i32) -> i32 {\n        let mut s = 0;\n        for i in 0..k{\n            let now:Vec<i32> = arr.iter().copied().skip(i as usize).step_by(k as usize).collect();\n            s += Solution::changes_needed(&now);\n        }\n        s\n    }\n    fn changes_needed(a: &[i32]) -> i32{\n        let mut dp:Vec<i32> = vec![];\n        for v in a{\n\t\t    // for v in a{\n\t\t\t//     let mut left:usize = 0;\n\t\t\t//     let mut right = dp.len();\n\t\t\t//     while left < right{\n\t\t\t//         let mid = left + (right - left)/ 2;\n\t\t\t//         if dp[mid] <= *v{\n\t\t\t//             left = mid + 1;\n\t\t\t//         }else{\n\t\t\t//             right = mid;\n\t\t\t//         }\n\t\t\t//     }\n\t\t\t//     if left == dp.len(){\n\t\t\t//        dp.push(*v)\n\t\t\t//     }else{\n\t\t\t//         dp[left] = *v;\n\t\t\t//     }\n\t\t\t// }\n\n            let t = dp.partition_point(|&x| x <= *v);\n            if t == dp.len(){\n                dp.push(*v);\n            }else{\n                dp[t] = *v\n            }\n        }\n        (a.len() - dp.len()) as i32\n    }\n}\n```
[]