相关推荐
【华为OD机试真题JAVA】水仙花数问题
所谓的水仙花数是指一个n位的正整数其各位数字的n次方的和等于该数本身, 例如153=1^3+5^3+3^3,153是一个三位数, 第一行输入一个整数N, 表示N位的正整数,N在3-7之间包含3,7 第二行输入一个正整数M, 表示需要返回第M个水仙花数
华为OD机试题 - 水仙花数 2(JavaScript)| 代码+思路+重要知识点
水仙花数 2 题目 给定非空字符串 s,将该字符串分割成一些子串 使每个子串的 ASCII 码值的和均为水仙花数 若分割不成功则返回 0 若分割成功且分割结果不唯一 则返回-1 若分割成功且分割结果唯一 则返回分割后子串的数目 输入 输入字符串的最大长度为 200 输出描述 根据题目中的情况返回响应结果
华为OD机试E卷 - 水仙花数 Ⅰ(Java & Python& JS & C++ & C )
所谓水仙花数,是指一个n位的正整数,其各位数字的n次方和等于该数本身。例如153是水仙花数,153是一个3位数,并且153 = 1^3 + 5^3 + 3^3。
2026华为OD机考新系统真题 + 双机位C卷 + 往年真题 - 题库目录分值说明 + 考点说明+在线OJ
2026年4月1日起,华为OD机试正式切换至新系统模式!采用力扣模式,无需自己写输入! 难度大幅度降低。正在备考华为OD机试的同学,优先刷新系统机试真题,可大幅提升通过率。 新系统考题考点与旧版一致,无需重新适应。本专栏所有算法题均配有详细思路解析,并提供C语言、JS、C++、Python、Go、Java多语言源码实现。订阅后私信即可开通专属OJ刷题权限,高效备考一次上岸!
华为OD机考2025B卷 - 水仙花数 Ⅰ(Java & Python& JS & C++ & C )
华为OD机考2025B卷 - 水仙花数 Ⅰ(Java & Python& JS & C++ & C )
【华为OD机试真题 JS语言】244、水仙花数Ⅱ | 机试真题+思路参考+代码分析
>给定非空字符串s,将该字符串分割成一些子串,使每个子串的ASCII码值的和均为水仙花数 1、若分割不成功,则返回0; 2、若分割成功且分割结果不唯一,则返回-1; 3、若分割成功且分割结果唯一,则返回分割后子串的数目
华为OD机试 - 水仙花数 Ⅰ(Java 2024 E卷 100分)
每一题都有详细的答题思路、详细的代码注释、样例测试,发现新题目,随时更新,全天CSDN在线答疑。
华为OD机试2024年E卷-水仙花数[100分]( Java | Python3 | C++ | C语言 | JsNode | Go )实现100%通过率
所谓的水仙花数是指一个n位的正整数其各位数字的n次方的和等于该数本身,例如153是一个三位数并且153 = 1^3 + 5^3 + 3^3。
水仙花数-
例如153是水仙花数,153是一个3位数,并且153=1^3+5^3+3^3。所谓 水仙花数,是指一个n位的正整数,其各位数字的n次方和等于该数本身。第一行输入一个整数n,表示一个n位的正整数。n在3到7之间,包含3和7。若m大于水仙花数的个数,返回最后一个水仙花数和m的乘积。第二行输入一个整数m,表示需要返回第m个水仙花数。返回长度是n的第m个水仙花数。若输入不合法,返回-1。153是第一个水仙花数.
华为OD机试真题 - 最大括号深度 (D卷,100分)
2024华为OD机试真题,代码包含语言java、js、python、c 代码基本都有详细注释。 题目描述 现有一字符串仅由 ‘(‘,’)’,'{‘,’}’,'[‘,’]’六种括号组成。 若字符串满足以下条件之一,则为无效字符串: ①任一类型的左右括号数量不相等; ②存在未按正确顺序(先左后右)闭合的括号。 输出括号的最大嵌套深度,若字符串无效则输出0。 0≤字符串长度≤100000 输入描述 一个只包括 ‘(‘,’)’,'{‘,’}’,'[‘,’]’的字符串 输出描述 一个整数,最大的括号深度
华为od真题水仙花数2
给定非空字符串s,将该字符串分割成一些子串,使每个子串的ASCII码值的和均为水仙花数(即3位的自幂数)。1.若分割不成功则返回0(包括本身满足条件,却无法正确分割的字符串)。2.若分割成功且分割结果不唯一,则返回-1。3.若分割成功且分割结果唯一,则返回分割后子串的数目。
【华为OD机试真题 Java语言】36、水仙花数 | 机试真题+思路参考+代码解析
所谓水仙花数,是指一个n位的正整数,其各位数字的n次方和等于该数本身。 例如153是水仙花数,153是一个3位数,并且153 = 1^3 + 5^3 + 3^3
【华为OD机试真题】36、水仙花数 | 机试真题+思路参考+代码解析(C++、Java、Py、JS)
题目描述 >所谓水仙花数,是指一个n位的正整数,其各位数字的n次方和等于该数本身。 例如153是水仙花数,153是一个3位数,并且153 = 1^3 + 5^3 + 3^3
深度学习、图像分类入门,从VGG16卷积神经网络开始
刚开始接触深度学习、卷积神经网络的时候非常懵逼,不知道从何入手,我觉得应该有一个进阶的过程,也就是说,理应有一些基本概念作为奠基石,让你有底气去完全理解一个庞大的卷积神经网络: 本文思路: 一、我认为学习卷积神经网络必须知道的几个概念: 1、卷积过程: 我们经常说卷积神经网络卷积神经网络,到底什么才是卷积?网络层卷积过程到底怎么实现?我们在这里借鉴了另一位博客大牛的动态图来给大
FMCW毫米波雷达原理一
1、简介 毫米波雷达的优点是角分辨率高、频带宽因而有利于采用脉冲压缩技术、多普勒颇移大和系统的体积小。目前笔者接触到的有24G毫米波雷达和77G毫米波雷达。 24G毫米波雷达主要应用在交通领域的测距和车辆测速,在其他领域也有使用24G毫米波雷达。 77G毫米波雷达主要应用在无人驾驶,汽车周围的目标检测等领域。 在首次接触雷达时,一头雾水。搞不清一个chirp的时域图和频域图的关系、中频信号以及其他名词的基本概念。在TI培训官网上看到一些毫米波雷达原理的视频才豁然开朗。TI培训官网毫米波传感介绍 本文主要是通
STM32F103VET6实战:用W25Q64外部Flash实现Bootloader+Application双备份(含完整代码解析)
本文详细介绍了基于STM32F103VET6微控制器和W25Q64外部Flash实现Bootloader+Application双备份固件升级的完整方案。通过精心设计的Flash分区策略、可靠的Bootloader程序以及包含双重校验和自动回滚机制的升级流程,有效解决了远程升级过程中断电导致设备变砖的风险,确保了工业嵌入式系统的高可靠性与稳定性。
RISC-V内核移植实战:从零开始手把手实现RT-Thread上下文切换(附GD32VF103代码解析)
本文详细解析了在RISC-V架构上移植RT-Thread实时操作系统的核心步骤,重点聚焦于上下文切换机制的实现。通过对比ARM Cortex-M与RISC-V在中断处理和寄存器管理上的关键差异,并以GD32VF103开发板为例,手把手指导开发者完成libcpu抽象层适配、线程栈初始化以及三种上下文切换方式的代码编写与调试,为嵌入式开发者从ARM转向RISC-V平台提供了实战指南。
【Unity Animation 2D】从零到一:骨骼绑定与IK动画实战指南
本文详细介绍了Unity中2D骨骼绑定与IK动画的实战流程,从角色素材准备、骨骼系统创建到权重绘制和IK设置,逐步指导开发者掌握2D动画制作技巧。通过反向动力学(IK)技术,实现更自然的角色动画效果,适用于游戏开发和动画制作。
【STM32项目】基于AI技术的多功能消防机器人(完整工程资料源码)
机器人通过巡逻扫描环境空间与障碍物、定位导航、探测物体/环境进行建模/自动地图测绘、扫描火焰、获取温湿度大小、获取空气安全情况来判断当前环境地点是否安全,检测到温度过高或检测到易燃、烟雾、有毒气体或摄像头识别到火焰时能够通过高压水泵喷射器来实现火焰隔离工作,蜂鸣器进行现场鸣笛报警,同时将当前环境温湿度大小、空气情况、环境地图、是否安全信息,将各个传感器来接收获取到的信息,实时发送到用户手机中的微信小程序,实现与用户远程监视功能,用户同时也能通过手机与电脑远程下发命令来操控机器人来实现交互功能
《Python全栈系列教程》专栏介绍及文章汇总
《Python全栈系列教程》专栏介绍及文章汇总
优化dalsa相机检测界面
上节实现了使用qt结合dalsa相机显示检测到缺陷的画面,由于窗口过于简陋,本节将进行一个界面优化。
深度学习工具包 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');```[](https://bitdeli.com/free "Bitdeli Badge")
efm32 入门.pdf
本PDF共计22页,介绍的是操作驱动API,下载与否自己斟酌。
pscad IEEE标准系统搭建说明
pscad IEEE标准系统搭建说明,包含典型的IEEE 9节点、14节点、30节点、39节点和118节点系统。内含标准测试系统的原始数据和潮流结果。
visio安装包
Microsoft Office Visio 是一款专业的制图软件。利用经过更新的形状、协作工具和数据链接图表,创建专业级图表以简化复杂的信息。
订阅专栏 解锁全文
414



被折叠的 条评论
为什么被折叠?



