当前位置:网站首页>[detailed explanation of Huawei machine test] check whether there is a digital combination that meets the conditions
[detailed explanation of Huawei machine test] check whether there is a digital combination that meets the conditions
2022-07-06 05:21:00 【A less intelligent programmer】
List of articles
Preface
《 Detailed explanation of Huawei's machine test questions Python Realization 》 The column includes Huawei column of niuke.com 、 Huawei test questions 、 Huawei OD Real problem of machine test .
If you are preparing for Huawei's interview , If you want to know something, you can send me a private letter , I will try my best to help you , I can also give you some suggestions !
This paper solves the non optimal solution ( Non optimal performance ).
Title Description
Given an array of positive integers Check whether there is an array combination that meets the rule in the array
The rules : A=B+2C
Input description :
The first line outputs the number of elements of the array The next line outputs all array elements Space off
Output description :
If there is a number that meets the requirements Output in sequence in the same line In the rules A/B/C The value of Space off If there is no output 0
Example 1
Input :
4
2 7 3 0
Output :
7 3 2
explain :
7=3+2*2
Example 2
Input :
3
边栏推荐
- nacos-高可用seata之TC搭建(02)
- Oracle query table index, unique constraint, field
- Force buckle 1189 Maximum number of "balloons"
- Ad20 is set with through-hole direct connection copper sheet, and the bonding pad is cross connected
- Building intelligent gray-scale data system from 0 to 1: Taking vivo game center as an example
- The ECU of 21 Audi q5l 45tfsi brushes is upgraded to master special adjustment, and the horsepower is safely and stably increased to 305 horsepower
- jdbc使用call调用存储过程报错
- ByteDance program yuan teaches you how to brush algorithm questions: I'm not afraid of the interviewer tearing the code
- [effective Objective-C] - memory management
- 驱动开发——HelloWDM驱动
猜你喜欢
Vite configures the development environment and production environment
RT thread analysis - object container implementation and function
剑指 Offer II 039. 直方图最大矩形面积
Figure database ongdb release v-1.0.3
注释、接续、转义等符号
Leetcode dynamic planning day 16
Cuda11.1 online installation
浅谈镜头滤镜的类型及作用
Yyds dry inventory SSH Remote Connection introduction
Modbus protocol communication exception
随机推荐
RT thread analysis - object container implementation and function
C Advanced - data storage (Part 1)
Quelques conseils communs sur l'inspecteur de l'unit é, généralement pour les extensions d'éditeur ou d'autres
Can the feelings of Xi'an version of "Coca Cola" and Bingfeng beverage rush for IPO continue?
Codeforces Round #804 (Div. 2)
自建DNS服务器,客户端打开网页慢,解决办法
Fluent implements a loadingbutton with loading animation
Zoom and pan image in Photoshop 2022
Excel转换为Lua的配置文件
Vite configures the development environment and production environment
js Array 列表 实战使用总结
A little knowledge of CPU, disk and memory
剑指 Offer II 039. 直方图最大矩形面积
Review of double pointer problems
[classic example] binary tree recursive structure classic topic collection @ binary tree
UCF(暑期团队赛二)
Simple understanding of interpreters and compilers
C AES encrypts strings
Pointer classic written test questions
04. Project blog log