自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(8)
  • 收藏
  • 关注

原创 203. Remove Linked List Elements

Remove all elements from a linked list of integers that have valueval. Example: Input: 1->2->6->3->4->5->6, val = 6 Output: 1->2->3->4->5 /** * Definition for ...

2020-05-05 16:02:18 98

原创 8. String to Integer (atoi)

Implement atoi whichconverts a string to an integer. The function first discards as many whitespace characters as necessary until the first non-whitespace character is found. Then, starting from thi...

2020-05-05 16:00:37 66

原创 7. Reverse Integer

Given a 32-bit signed integer, reverse digits of an integer. Example 1: Input: 123 Output: 321 Example 2: Input: -123 Output: -321 Example 3: Input: 120 Output: 21 Note: Assume we are dealing with...

2019-12-16 14:00:42 75

原创 5. Longest Palindromic Substring

Given a string s, find the longest palindromic substring in s. You may assume that the maximum length of s is 1000. Example 1: Input: "babad" Output: "bab" Note: "aba" is also a valid answer. Exampl...

2019-12-13 18:34:39 80

原创 3. Longest Substring Without Repeating Characters

Given a string, find the length of the longest substring without repeating characters. Example 1: Input: "abcabcbb" Output: 3 Explanation: The answer is "abc", with the length of 3. Example 2: In...

2019-12-13 14:32:27 64

原创 2. Add Two Numbers

You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return i...

2019-11-07 17:05:14 57

原创 1. Two sum

题目描述 给定一个整型数组,要求返回两个数的下标,使得两数之和等于给定的目标值,要求同一个下标不能使用两次。 数据保证有且仅有一组解。 样例 给定数组 nums = [2, 7, 11, 15],以及目标值 target = 9, 由于 nums[0] + nums[1] = 2 + 7 = 9, 所以 return [0, 1]. 算法1: (暴力枚举)O(n^2) 使用两个循环实...

2019-11-06 16:44:03 108

原创 机器学习实战 笔记一:kNN分类算法

开发机器学习应用程序的步骤: 1、收集数据 2、准备输入数据 3、分析输入数据 4、训练算法 5、测试算法 6、使用算法 第一个算法:k-近邻算法 k-近邻算法的一般流程: 1、收集数据:可以使用任何方法 2、准备数据:距离计算所需要的数值,最好是结构化的数据格式,此时需要对数据进行格式化 3、分析数据:可以使用任何方法 4、训练算法:此步骤不适合用于k-近

2017-03-23 20:41:43 324

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除