background picture of the home page

Hi,Friend

Krahets题目记录8

请你仅使用两个栈实现先入先出队列。队列应当支持一般队列支持的所有操作(push、pop、peek、empty): 实现 MyQueue 类: void push(int x) 将元素 x 推到队列的末尾 int pop() 从队列的开头移除并返回元素 int peek() 返回队列开头的元素 boo

thumbnail of the cover of the post

Krahets题目记录7

设计一个支持 push ,pop ,top 操作,并能在常数时间内检索到最小元素的栈。 实现 MinStack 类: MinStack() 初始化堆栈对象。 void push(int val) 将元素val推入堆栈。 void pop() 删除堆栈顶部的元素。 int top() 获取堆栈顶部的元

thumbnail of the cover of the post

Krahets题目记录6

给定一个只包括 '(',')','{','}','[',']' 的字符串 s ,判断字符串是否有效。 有效字符串需满足: 左括号必须用相同类型的右括号闭合。 左括号必须以正确的顺序闭合。 每个右括号都有一个对应的相同类型的左括号。 示例 1: 输入:s = "()"

thumbnail of the cover of the post

Krahets题目记录5

给你一个长度为 n 的链表,每个节点包含一个额外增加的随机指针 random ,该指针可以指向链表中的任何节点或空节点。 构造这个链表的 深拷贝。 深拷贝应该正好由 n 个 全新 节点组成,其中每个新节点的值都设为其对应的原节点的值。新节点的 next 指针和 random 指针也都应指向复制链表中

thumbnail of the cover of the post

Shader开发相关-计算机图形程序接口

计算机图形程序接口 计算机图形程序接口(Graphics API)对于游戏开发程序员来说是非常重要的知识,是学习图形学时必不可少的内容。 计算机图形程序接口是一套可编程的开放标准,不管做2D还是3D游戏都需要这部分的底层API支持。 它本质上是软件,并不是硬件,是前辈们提前为你写好的调用系统硬件(G

thumbnail of the cover of the post

C#时间相关

using System; using System.Collections; using System.Collections.Generic; using UnityEngine; public class Lesson12 : MonoBehaviour { // Start is

thumbnail of the cover of the post

C#8语法相关

using System; using System.Collections; using System.Collections.Generic; using System.IO; using UnityEngine; public class TestUsing : IDisposable {

thumbnail of the cover of the post

C#7相关语法

using System.Collections; using System.Collections.Generic; using UnityEngine; public struct TestRef { public int atk; public int def; p

thumbnail of the cover of the post