Skip to content

Instantly share code, notes, and snippets.

View awslambda.bootstrap.py
# -*- coding: utf-8 -*-
# /var/runtime/awslambda/bootstrap.py
"""
aws_lambda.bootstrap.py
Amazon Lambda
Copyright (c) 2013 Amazon. All rights reserved.
Lambda runtime implemention
"""
View waterfill
var calculate = function( arr ) {
var air_sum = 0;
var ground_sum = 0;
var last = arr.length - 1;
var left_max = arr[0];
var right_max = arr[last];
for ( var i = 0; i <= last; i++ ) {
var el = arr[ i ];
You can’t perform that action at this time.