MCPcopy Create free account
hub / github.com/LjyYano/LeetCode / L0027_RemoveElement

Class L0027_RemoveElement

src/main/java/L0027_RemoveElement.java:8–73  ·  view source on GitHub ↗

题目链接:https://leetcode.cn/problems/remove-element/ 给你一个数组 nums 和一个值 val,你需要 原地 移除所有数值等于 val 的元素,并返回移除后数组的新长度。 不要使用额外的数组空间,你必须仅使用 O(1) 额外空间并 原地 修改输入数组。 元素的顺序可以改变。你不需要考虑数组中超出新长度后面的元素。

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected