mirror of
https://github.com/krahets/hello-algo.git
synced 2026-04-05 11:41:22 +08:00
Bug fixes and improvements (#1078)
* Fix the logo in the en version * Optimize header color and fix body background color * Update theme switch's name * Fix backfrop-filter on Safari * Update some animation's file name for adding egde when cropping * Re-count the comments number * A bug fix in n_queens_problem.md
This commit is contained in:
@@ -347,19 +347,19 @@
|
||||
如下图所示,我们将双向链表的头节点和尾节点视为双向队列的队首和队尾,同时实现在两端添加和删除节点的功能。
|
||||
|
||||
=== "LinkedListDeque"
|
||||

|
||||

|
||||
|
||||
=== "push_last()"
|
||||

|
||||

|
||||
|
||||
=== "push_first()"
|
||||

|
||||

|
||||
|
||||
=== "pop_last()"
|
||||

|
||||

|
||||
|
||||
=== "pop_first()"
|
||||

|
||||

|
||||
|
||||
实现代码如下所示:
|
||||
|
||||
@@ -372,19 +372,19 @@
|
||||
如下图所示,与基于数组实现队列类似,我们也可以使用环形数组来实现双向队列。
|
||||
|
||||
=== "ArrayDeque"
|
||||

|
||||

|
||||
|
||||
=== "push_last()"
|
||||

|
||||

|
||||
|
||||
=== "push_first()"
|
||||

|
||||

|
||||
|
||||
=== "pop_last()"
|
||||

|
||||

|
||||
|
||||
=== "pop_first()"
|
||||

|
||||

|
||||
|
||||
在队列的实现基础上,仅需增加“队首入队”和“队尾出队”的方法:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user