Halo

A magic place for coding

0%

Introduction

  今天我们来聊聊网关(Gateway)。在当下微服务架构的潮流下,网关是一个很重要的部分。在这篇博客,我们将一起了解网关的基本架构、功能等。

Read more »

Introduction

  堡垒机这个概念是在运维领域中的一个概念,在系统维护过程中会经常接触到,这篇博客就来向大家介绍一下堡垒机。

Read more »

Introduction

 在买电脑的时候我们一般都会关注硬盘、内存这些指标,而在系统运维过程中,我们同样也关注系统的内存情况。在这篇博客我将对这些基础的概念简单介绍,以及谈一下一些相关的实践经历。

Read more »

Introduction

  网络方面的知识之前一直介绍的比较少,今天就从最基础的DNS开始分享下,主要是把一些基础的概念搞清楚,基础打好了后面才容易理解。

Read more »

Introduction

  现在的软件工程领域中,经常会听到HTTP(Hyper Text Transport Protocol)和RPC(Remote Procedure Call)这两个术语,好像都是和接口、网络请求有关,但是它们究竟是什么,是不是对等的两样东西,它们之间的关系和优缺点是什么,很多朋友都没有弄清楚。所以在这篇博客,我将简单梳理一下HTTP和RPC相关的知识。

Read more »

Problem

Alice and Bob take turns playing a game, with Alice starting first.

There are n stones arranged in a row. On each player’s turn, they can remove either the leftmost stone or the rightmost stone from the row and receive points equal to the sum of the remaining stones’ values in the row. The winner is the one with the higher score when there are no stones left to remove.

Bob found that he will always lose this game (poor Bob, he always loses), so he decided to minimize the score’s difference. Alice’s goal is to maximize the difference in the score.

Given an array of integers stones where stones[i] represents the value of the ith stone from the left, return the difference in Alice and Bob’s score if they both play optimally.

Read more »

Problem

You are given a 0-indexed integer array nums and an integer k.

You are initially standing at index 0. In one move, you can jump at most k steps forward without going outside the boundaries of the array. That is, you can jump from index i to any index in the range [i + 1, min(n - 1, i + k)] inclusive.

You want to reach the last index of the array (index n - 1). Your score is the sum of all nums[j] for each index j you visited in the array.

Return the maximum score you can get.

Read more »