leetcode:1. Two Sum

基于matlab的CNN物体识别物体分类系统 主要对物体进行识别,搭建一个物体分类系统本次实验选择规模稍大的 CIFAR-10 数据集进行分类识别,对应图像的大小设计 VggNet、ResNet 进行网络训练。在实际操作过程中,受限于数据规模和硬件配置,对于大小放缩、批次参数、训练步数等进行了多次调试,这也对以后的图像分类任务具有较高的参考意义,并通过对 CIFAR-10 数据集进行训练和评测,采用网络修改的方式来得到新的 CNN 结构,适用于对网络进行配置、融合等相关研究。读者可以通过自行设计或选择其他网络、加载其他数据等方式进行实验的延伸。 阅读详情

如何优化呢:

 

没考虑负数,错误,,,

/*
1.寻找加起来等于某个数的两个数,返回其小标

*/
class Solution {
public:
    vector<int> twoSum(vector<int>& nums, int target) {
        // sort(nums.begin(),nums.end);
        int len=nums.size();
        vector<int> res;
        for(int i=0;i<len && nums[i]<=target;i++)
        {
            
            for(int j=i+1;j<len && nums[i]<=target;j++)
            {
                if(nums[i]+nums[j] == target) res={j,i};
            }
        }
        return res;
        
    }
};

 

 

可是得怎么优化呢?如何做到只用一个for?

/*
1.寻找加起来等于某个数的两个数,返回其小标

*/
class Solution {
public:
    vector<int> twoSum(vector<int>& nums, int target) {
        // sort(nums.begin(),nums.end);
        int len=nums.size();
        vector<int> res;
        for(int i=0;i<len ;i++)
        {
            
            for(int j=i+1;j<len ;j++)
            {
                if(nums[i]+nums[j] == target) res={j,i};
            }
        }
        return res;
        
    }
};

 

看大佬解法:

 

Accepted C++ O(n) Solution

vector<int> twoSum(vector<int> &numbers, int target)
{
    //Key is the number and value is its index in the vector.
	unordered_map<int, int> hash;
	vector<int> result;
	for (int i = 0; i < numbers.size(); i++) {
		int numberToFind = target - numbers[i];

            //if numberToFind is found in map, return them
		if (hash.find(numberToFind) != hash.end()) {
                    //+1 because indices are NOT zero based
			result.push_back(hash[numberToFind] + 1);
			result.push_back(i + 1);			
			return result;
		}

            //number was not found. Put it in the map.
		hash[numbers[i]] = i;
	}
	return result;
}

为啥要+1??

大佬写错了,不应该+1

 

这个更清晰点,

vector<int> twoSum(vector<int>& nums, int target) {
        unordered_map<int, int> map;
            
        for(int i =0; i< nums.size(); i++){
             int complement = target - nums[i];
             if(map.find(complement) != map.end()){
                 return {map[complement], i};
              } 
            
              map[nums[i]] = i;
         }   
        
        return {};
    }

 

C# HttpClient完全攻略:从入门到精通只需5步 HttpClient是.NET框架中用于发送HTTP请求和接收HTTP响应的类。它基于异步编程模型,使得网络操作更加高效和灵活。 阅读详情

相关推荐

VIPER22A实战:从零搭建15W非隔离电源,附BUCK电路调试心得

本文详细介绍了使用VIPER22A芯片从零搭建15W非隔离电源的全流程,重点解析BUCK电路设计与调试技巧。通过核心参数计算、PCB布局优化和效率提升方案,帮助工程师快速掌握DC-DC电源设计要点,实现高效稳定的电源转换。

redis7keeper的博客 685

LeetCode 1 Two Sum题解

题目地址:https://leetcode.com/problems/two-sum/ 1. Two Sum 难度:简单 Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that e

赞美月亮的专栏 667

四阶龙格库塔方法求解一次常微分方程组

四阶龙格库塔方法求解一次常微分方程组一、写在前面二、四阶龙格库塔方法三、使用四阶龙格库塔方法求解一次常微分方程组 一、写在前面 龙格库塔方法是数值求解常微分非线性方程的有利工具,计算精度较高,通过缩短步进距离和增加阶数可以进一步控制误差范围。工程上较为常用的是四阶龙格库塔算法(R-K4),在计算收敛的情况下往往可以得到比较好的结果。 二、四阶龙格库塔方法 这里简单介绍一下算法的具体实现过程,不做详细的推导。其求解的问题是形如方程: y˙=f(y,t),其中t∈[t0,t1]初值y(t0)=c0 \dot{y

HelloWorldTM的博客 2万+

Leetcode力扣 1 | 两数之和 Two Sum —— python

Leetcode力扣 1 | 两数之和 Two SumQuestionAnswerBrute Force 暴力求解法HashTable 哈希表法 该系列以提高编程能力、学习数据结构与算法为目的 编程语言:python Question 给定一个数组nums、一个目标target值(以下简写成nums、target) 我们的目的是在nums中,找到两个元素,使其相加等于target值,然后返回这两个元素在nums中的索引,就是数组下标。 题目中给了三个示例: 第一个返回下标0和1,因为2与7的和为9

idl1ng的博客 1143

从标准到实战:详解IEC 61000-4-2下的ESD电路防护设计

本文深入解析IEC 61000-4-2标准下的ESD电路防护设计,从静电防护的基础原理到实战应用。详细介绍了接触放电与空气放电的区别、防护器件选型要点(如TVS管和压敏电阻)以及PCB布局的黄金法则,帮助工程师有效提升电子产品的抗静电能力,确保设备在严苛环境下的稳定运行。

weixin_33704234的博客 516

UNet改进(6):基于注意力机制的多尺度医学图像分割方法

本文提出了一种集成多尺度注意力机制的UNet改进模型UNetWithAttention,用于提升医学图像分割性能。该模型在标准UNet架构基础上,设计了并行3×3、5×5、7×7卷积核的多尺度注意力模块,通过特征拼接和Sigmoid激活生成注意力权重,实现了对不同尺寸病变的自适应关注。模型采用分离式设计,将特征提取与特征选择解耦,在编码器-解码器各阶段嵌入注意力模块。实验表明,该方法在视网膜血管分割和肺结节检测任务中优于标准UNet,Dice系数和IOU分别提升2.6%和4.1%,同时保持计算效率。

2501_91516851的博客 1329

LeetCode 1. Two Sum 题解

本题是算法的经典入门问题,主要考察对哈希表的理解和应用。通过使用哈希表,我们可以将时间复杂度从 O(n²) 降低到 O(n),大大提高了算法的效率。哈希表的核心思想是:通过哈希表来存储已经遍历过的元素及其下标,这样当我们遍历到当前元素时,可以在 O(1) 的时间复杂度内检查目标值与当前元素的差值是否已经存在于哈希表中。这种方法不仅适用于两数之和问题,还可以应用于许多其他需要快速查找元素的场景。掌握哈希表的使用,对于解决这类问题非常重要。

cannonjinx的博客 4199

视觉测量实战:C#上位机+OpenCVSharp 实现工业零件尺寸自动检测(精准像素级,工业级可落地)

本次开发的上位机界面遵循工业现场操作规范简洁、直观、按钮大、文字清晰、参数可视化调节,操作人员为车间工人/质检员,无需复杂操作,所有控件均为WinForms原生控件,拖拽即可完成布局本次实战完成了C#上位机+OpenCVSharp 工业零件尺寸自动检测系统的完整开发,这套方案是工业视觉测量的标准落地方案,适配95%的规则几何零件的尺寸检测场景,从五金件、塑胶件到电子元件,全覆盖无死角。测量效率提升100倍、精度提升10倍、无人工误差、可适配流水线实时检测。

这里只有干货:从 Modbus 通信到 MES 对接,从 YOLO 训练到工控机部署,带你搞定工业软件开发全流程。 854

[LeetCode] No.1 Two Sum

“做程序员太辛苦了,我想换行……我该怎么办?” “敲一下回车。” Two Sum(两数之和) 题目: 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...

但行好事 莫问前程 348

【Pytorch实战教程】基于RML2018的融合网络分类 | LSTM网络和ResNet网络融合 | 含数据集的处理

这段代码是从原始数据中读取所选择的数据,画出星座图,并将星座图保存本地,然后将IQ数据保存成mat文件,将图片数据读取之后保存为npy文件,方便后续融合网络使用。

若北辰 934

在时间轴上联动多张内表:ABAP 的 PROVIDE ... ENDPROVIDE 区间联动迭代实战

PROVIDE 是 ABAP 中处理有效期区间数据的强大工具,它能自动将多张内表按时间维度切片并联合处理。其核心功能包括:指定区间边界字段(BOUNDS),定义外部总区间(BETWEEN),并通过工作区和标志位(VALID)标识每张表在当前子区间是否生效。该语法特别适合 HR 信息类型等有效期数据,能避免手动处理区间重叠、排序和空档等问题。使用时需注意字段投影(FIELDS)限制、工作区只读原则,以及异常处理(如区间重叠或未排序)。典型应用场景包括员工调岗记录、价格有效期管理等需要时间轴联动的业务逻辑。

2007 年 ~ 2025 年,深耕 SAP 技术 18 年 1679

Leetcode ☞ 1. Two Sum ☆ 【Hashmap】

给一数组和一target数,有两个元素的和为target。求这两个元素的下标的和。

Dr_Unknown的博客 986

华为OD机试真题 新系统2026-04-01 C语言 实现【空间占用计算】

员工A的磁盘空间经常被耗尽,他需要找到占用空间最大的目录或文件,然后决定如何清理文件释放空间。给定某一目录,请编写程序帮助他统计该目录内一级子目录和文件的占用空间,并返回目标目录一级子项(文件或子目录)中占用空间最大的项。

MISAYAONE的博客 235

力扣Leetcode1 | 两数之和(Two Sum)

暴力法、一次哈希表和两次哈希表法 https://blog.csdn.net/zhushaojiecumt/article/details/102846196 视频: https://www.bilibili.com/video/BV1Li4y1E7gT?p=1 双指针法 如果列表是无序的,需要先排序,使用双指针,分别指向头、尾。如果两数之和大于target,尾指针前移,如果两数之和小于target,首指针后移。 class Solution: def twoSum(self, nums: List

maoersong的专栏 359

数学建模模型总结

这是本人在两年内准备参加数学建模竞赛搜集到的模型资料,已经经过了本人的筛选和整理,希望能够对准备参加数学建模竞赛的学弟学妹们提供一些帮助!

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

Leetcode 1 Two Sum

Question : Two Sum 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...

嗨~ 173

WINCC7.3破解文件

WINCC7.3硬件够破解文件,有需要的下载!WINCC7.3硬件够破解文件,有需要的下载!

LeetCode 1 Two Sum——在数组上遍历出花样

本文始发于个人公众号:TechFlow 今天是周末,和大家一起来看一道算法题。这道题是大名鼎鼎的LeetCode的第一题,也是面试当中非常常见的一道面试题。题目不难,但是对于初学者来说应该还是很有意思,也是一道很适合入门的算法题。 废话不多说,让我们一起来看看题目吧。 Given an array of integers, return indices of the two numbers su...

TechFlow的博客 231

霍尼韦尔SoftMaster使用说明

霍尼韦尔SoftMaster使用说明

Leetcode 1. Two Sum

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...

Smiling_Wang的博客 268

【LeetCode with JavaScript】1.Two Sum

原题网址:https://leetcode.com/problems/two-sum/ 难度:Easy 题目 给定一个整数数组和一个目标值,找出数组中和为目标值的两个数。 你可以假设每个输入只对应一种答案,且同样的元素不能被重复利用。 Example: 给定 nums = [2, 7, 11, 15], target = 9 因为 nums[0] + nums[1] = 2 ...

zwkkkk1的博客 1029

LeetCode 1.Two Sum map 初次使用Markdown*****

外传 经过室友推荐blog转战Markdown编辑,初次使用还觉得挺不方便需要那么多快捷键,不如鼠标点的快。今天这一篇文章才写一半就觉得很好用,就像电脑操作用鼠标点击和windows快捷键操作一样爽,在此向还没转战的朋友推荐,顺便练习自己的操作。 不方便的是代码高亮显示不好。 参考快速上手 记录插入链接格式 题目 题意 注意 思路1 代码

老夫编代码就是一把梭 1146

java two sum 讲解_【LeetCode 力扣】1. Two Sum 两数之和 Java 解法

LeetCode的第一题,英文单词书中 Abandon 一般的存在,让我们来看一下题目:Given an array of integers, returnindicesof the two numbers such that they add up to a specific target.You may assume that each input would haveexactlyo...

weixin_36072221的博客 217

LeetCode力扣 1. 两数之和 Two Sum 题解代码 JavaScript

问题 https://leetcode-cn.com/problems/two-sum/ 练习使用JavaScript解答 /** * @param {number[]} nums * @param {number} target * @return {number[]} */ var twoSum = function(nums, target) { var i, j = nums.length-1, sum; var num2 = []; for(i=0;i&lt

Coding home - 漂流瓶jz 592

Leetcode学习笔记:#1 Two Sum

Leetcode学习笔记:#1 Two Sum 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 yo...

ccystewart的博客 211

[leetCode-1]two-sum (java version)

[leetCode-1]two-sum 欢迎使用Markdown编辑器 你好! 这是你第一次使用 Markdown编辑器 所展示的欢迎页。如果你想学习如何使用Markdown编辑器, 可以仔细阅读这篇文章,了解一下Markdown的基本语法知识。 新的改变 我们对Markdown编辑器进行了一些功能拓展与语法支持,除了标准的Markdown编辑器功能,我们增加了如下几点新功能,帮助你用它写博客: ...

fruitful1989的博客 153

【Leetcode】1. Two Sum

题目地址: https://leetcode.com/problems/two-sum/ 在一个数组中寻找两个数其和为给定的target,返回这两个数的下标。 思路是用一个哈希表存储数字和其对应的下标,一旦发现target与某个数之差在哈希表里已经存在,就返回两个下标。代码如下: import java.util.HashMap; import java.util.Map; public cla.........

数学、算法爱好者的博客 163

【仅用于个人整理记忆】LeetCode算法题之1. Two Sum(easy)

声明: 如标题所示,因本人为AI路上的新手,文章仅用于辅助个人的整理记忆,理解难免有偏差之处,都是个人拙见,如给其他同僚造成困扰,还请见谅,非常非常非常欢迎私信共同讨论,共同进步 题目描述如下: Given an array of integers, return indices of the two numbers such that they add up to a specific targ...

DaMoWangZQ的博客 273

LeetCode1. Two Sum

LeetCode 1.Two Sum

jessir的专栏 358
上一篇: leetcode:70. Climbing Stairs
下一篇: leetcode:53. Maximum Subarray
nedwons
博客等级 码龄9年 311粉丝 572原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值