本博客持续更新整理关于面试时最容易被问到的一些关于Python的问题,虽然平时没少用,但是一关上电脑被问python的基本数据类型都说不全…

new beginning
Given two integer arrays A and B,return the maximun length of an subarray that appears in both arrays
给两个整数数组 A 和 B ,返回两个数组中公共的、长度最长的子数组的长度。
Example:
1 | 输入: |
难度:中等
Given a string containing just the characters ‘(‘ and ‘)’, find the length of the longest valid (well-formed) parentheses substring.
给定一个只包含 '(' 和 ')' 的字符串,找出最长的包含有效括号的子串的长度。
难度:困难
Given an array of integers, return indices of the two numbers such that they add up to a specific target.
You may assume that each input would have exactly one solution, and you may not use the same element twice.
给定一个整数数组 nums 和一个目标值 target,请你在该数组中找出和为目标值的 两个 整数。
你可以假设每种输入只会对应一个答案。但是,你不能重复利用这个数组中同样的元素。