当前位置:网站首页>[benefit activity] stack a buff for your code! Click "tea" to receive the gift
[benefit activity] stack a buff for your code! Click "tea" to receive the gift
2022-07-27 20:35:00 【Amazon cloud developer】
Welfare activities
2022 Season two
The scorching summer fades
Welfare activities officially kicked off
From now on to 7 month 25 Friday night
Just get involved User Group Welfare activities
Submit participation code
Learning experience development deployment program
You can get 【 Naixue's tea coupon 】
In a tired afternoon
Have a drink User Group
Naixue's tea for everyone
01、 Participate in the way
Any AWS All partners of the account can participate , Everyone can participate once .
02、 The rules of the game
By writing Python The code implements the following calculation .
A laboratory has accumulated n Calculation jobs to be run , In order to complete these assignments , The laboratory rented a server for continuous free Machine hours of units .
We use a length of n Array of times Indicates the processing time required for each job , among times[i] It means the first one i Processing time required for jobs . The lab wants to run enough jobs with these machines . Give you an array of processing times times and free, Please calculate and return to the Laboratory free The maximum number of jobs that a unit can complete .
Be careful : Jobs can be executed in any order .
A single job needs to be completed continuously , Job execution cannot be interrupted .
03、 Submit request
Please submit a single Python Source file To solve the above problem .
04、 Code execution environment
Python 3.9 / 128MB memory Other class libraries available : AWS SDK for Python Specific version information , Please refer to the documentation ( Copy the link and open it in the browser )Lambda runtimes - AWS Lambda
05、Python Code requirements
The code must include the following entry functions , Get from s3 File path as a parameter , And return the calculation result required above .
The format of input file content is ,
free_number\ttimes[0],times[1],times[2],...,times[n]
def handler(event, context): inputfile = event['url']
# input Is the target S3 file , The format is similar s3://mybucket-name/myfiles/inputfile1
result = yourmethod_find_maximum_number_of_jobs(inputfile)
return resultExample : Input event:{"url": "s3://mybucket-name/myfiles/inputfile1"}s3://mybucket-name/myfiles/inputfile1 The content of the document is :20\t3,8,8,10 Input above indicates times = [3, 8, 8, 10], free = 20 Output :3 explain : The laboratory can complete the subscript 0、1、2 The homework , The total time is 3 + 8 + 8 = 19
06、 Submit code steps
Step one
Register an Amazon cloud account (https://s.awsevents.cn/1cg8t4 Copy to the browser to open or click directly Read the original To jump ), And log in to the console . Existing accounts can be used .( You can click the picture to zoom in and see the specific operation )

Step two
Create a new API( You can click the picture to zoom in and see the specific operation )





Please note that Lambda Please fill in the following content at the function arn:aws:lambda:ap-southeast-1:324908031092:function:contest-checker-checker31A6B3BF-td0E0mBsHMyY
notes : The function string does not contain spaces until here You have successfully created API 了 ~
Step three
Submit the completed procedure to User Group Intelligent assistant judges and redeems rewards . The format is as follows HTTP form-data Submit the form to your previously deployed API Interface .
"eventId": "20220701",
# Required , The activity code of this period is 20220701, Do not modify the
"nickname": Your name is ,
# Required , Your nickname "result": Challenging code files
# Required , To achieve the task of this period Python Code file Step 3 example :
1. Use the programmer's favorite command line tool to submit examples curl -F eventId=20220701 -F [email protected]/home/myname/aws-user-group-challenge.py -F nickname= Xiaofeixia https://.execute-api.ap-northeast-1.amazonaws.com
2. Use graphics HTTP Request tool Postman Submit sample

Q1 : Participating in activities will bring benefits ?A: Of course. ! Who let User Group Favorite fan developer ! Every developer who successfully runs this activity , The system will directly distribute 【 Naixue's tea coupon 】, In a tired afternoon , Have a cup of Amazon cloud technology User Group Here is Naixue's tea for you !
Q2 : adopt HTTP Methods will participate in the submission of works , Is there anything else to do ?A: No more than 30 Seconds of waiting , If the submission is correct , You will immediately receive the tea code of electronic Naixue ; If the error , The system will remind you to test once .
And remember to pay attention to official account 【User Group】, Otherwise, don't blame small U I didn't remind you to get more activity benefits ! See below for details of benefits !
Q3 : There are other benefits ?A: There has to be ! besides , We will select the top ten participants and send them to Amazon cloud technology User Group A nice one !
Ranking method : On the premise of successful operation , Rank according to the completion time . The list will be tweeted later , We must continue to pay attention to official account 【User Group】, Reply to the receiving information , In order to receive benefits as soon as possible !
Q4 : Series of activities are related every time ?A: There must be ! It's not just , Plus benefits !
This series of welfare activities is a multi issue serial model , If developers who participated in the welfare activities at the beginning of the year , We will record the participation for you , And selected in the year-end award 【 Annual talent 】, Give the annual mysterious gift !
ha-ha ! Don't worry if you don't catch up with the activities at the beginning of the year , from now on , Join in ! Scan code into group ! The time is now , Don't miss a game User Group A series of welfare activities ! Let's accumulate the number of participation ! You are the man of the year !

边栏推荐
- slf4j中如何进行log4j配置呢?
- ZJNU 22-07-26 比赛心得
- 《安富莱嵌入式周报》第275期:2022.07.18--2022.07.24
- Adjust the array so that odd numbers all precede even numbers
- 为什么需要第三方支付?
- C language POW function (how to play exponential function in C language)
- 学习Blender必备的12款动画插件,来了解一下
- JS realizes video recording - Take cesium as an example
- Assignment 1 - Hello World ! - Simple thread Creation
- 继华为、联发科之后,这家手机芯片厂商宣布向武汉捐款700万
猜你喜欢

Understand the wonderful use of dowanward API, and easily grasp kubernetes environment variables

PyQt5快速开发与实战 4.7 QSpinBox(计数器) and 4.8 QSlider(滑动条)

Oracle Xe installation and user operation

My approval of OA project (Query & meeting signature)

If you want to switch to software testing, you should pass these three tests first, including a 3000 word super full test learning guide

JS realizes video recording - Take cesium as an example

办公自动化解决方案——DocuWare Cloud 将应用程序和流程迁移到云端的完整的解决方案

Redis-基本了解,五大基本数据类型

Connection pool - return connection details (Part 1)

C语言--数组
随机推荐
IE11 下载doc pdf等文件的方法
Understand the wonderful use of dowanward API, and easily grasp kubernetes environment variables
Redis thing learning
康佳首批10万颗存储主控芯片售罄,2020年预计销量1亿颗
PyQt5快速开发与实战 4.5 按钮类控件 and 4.6 QComboBox(下拉列表框)
MediaTek releases Helio g80, a mid-range game phone chip
2019年全球半导体市场收入4183亿美元,同比下滑11.9%
C language -- array
In 2019, China's smart machine Market: Huawei won nearly 4 components, firmly ranking first in China
ZJNU 22-07-26 competition experience
uva1421
华为手机出货超苹果成全球第二,但面临大量库存需要清理
继华为、联发科之后,这家手机芯片厂商宣布向武汉捐款700万
[rctf2015]easysql-1 | SQL injection
Set -- data deconstruction
C语言pow函数(c语言中指数函数怎么打)
C language POW function (how to play exponential function in C language)
To share the denoising methods and skills of redshift renderer, you must have a look
Huiding Technology: the acquisition of NXP vas business has been completed
shell