#
#
# @param num int整型一维数组
# @return int整型二维数组
#
class Solution:
def threeSum(self , num ):
# write code here
package main
/**
*
* @param num int整型一维数组
* @return int整型二维数组
*/
func threeSum( num []int ) [][]int {
// write code here
}
/**
*
* @param num int整型一维数组
* @param numLen int num数组长度
* @return int整型二维数组
* @return int* returnSize 返回数组行数
* @return int** returnColumnSizes 返回数组列数
*/
int** threeSum(int* num, int numLen, int* returnSize, int** returnColumnSizes ) {
// write code here
}
#
# 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
#
# @param num int整型一维数组
# @return int整型二维数组
#
class Solution
def threeSum(num)
# write code here
end
end
object Solution {
/**
* 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
*
* @param num int整型一维数组
* @return int整型二维数组
*/
def threeSum(num: Array[Int]): Array[Array[Int]] = {
// write code here
}
}
object Solution {
/**
* 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
*
* @param num int整型一维数组
* @return int整型二维数组
*/
fun threeSum(num: IntArray): Array{
// write code here
}
}
import java.util.*;
public class Solution {
/**
* 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
*
* @param num int整型一维数组
* @return int整型二维数组
*/
public int[][] threeSum (int[] num) {
// write code here
}
}
/**
* 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
*
* @param num int整型一维数组
* @return int整型二维数组
*/
export function threeSum(num: number[]): number[][] {
// write code here
}
public class Solution {
/**
* 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
*
* @param num int整型一维数组
* @return int整型二维数组
*/
func threeSum ( _ num: [Int]) -> [[Int]] {
// write code here
}
}
struct Solution{
}
impl Solution {
fn new() -> Self {
Solution{}
}
/**
* 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可
*
* @param num int整型一维数组
* @return int整型二维数组
*/
pub fn threeSum(&self, num: Vec) -> Vec> {
// write code here
}
}
[-2,0,1,1,2]
[[-2,0,2],[-2,1,1]]