当前位置:网站首页>[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 !

边栏推荐
- leetcode:1498. 满足条件的子序列数目【排序 + 二分 + 幂次哈希表】
- Graphic leetcode - Sword finger offer II 115. reconstruction sequence (difficulty: medium)
- 多点双向重发布及路由策略的简单应用
- JD: search product API by keyword
- Redis thing learning
- Preprocessing and macro definition
- Redis-基本了解,五大基本数据类型
- C语言pow函数(c语言中指数函数怎么打)
- 2022.07.11
- Slf4j introduction
猜你喜欢

发布2年后涨价100美元,Meta Quest 2的逆生长

Check the internship salary of Internet companies: with it, you can also enter the factory

Use cpolar to build a business website (5)

Redis thing learning

2022.07.11

站在巨人肩膀上学习,京东爆款架构师成长手册首发

I'm also drunk. Eureka delayed registration and this pit

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

Idea: solve the problem of code without prompt

我也是醉了,Eureka 延迟注册还有这个坑
随机推荐
Injection attack
To share the denoising methods and skills of redshift renderer, you must have a look
使用cpolar建立一个商业网站(5)
Graphic leetcode - Sword finger offer II 115. reconstruction sequence (difficulty: medium)
ES6 -- Deconstruction assignment
Common methods of object learning [clone and equals]
uva1421
IE11 下载doc pdf等文件的方法
我也是醉了,Eureka 延迟注册还有这个坑
调整数组使奇数全部都位于偶数前
为什么需要第三方支付?
康佳首批10万颗存储主控芯片售罄,2020年预计销量1亿颗
Oracle Xe installation and user operation
Simple application of multipoint bidirectional republication and routing strategy
How to configure log4j in slf4j?
站在巨人肩膀上学习,京东爆款架构师成长手册首发
JD: get the raw data API of commodity details
JD: search product API by keyword
es6删除对象的属性_ES6删除对象中的某个元素「建议收藏」
Following Huawei and MediaTek, the mobile phone chip manufacturer announced a donation of 7million yuan to Wuhan