Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions FitstExperiment/first.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include<stdio.h>
#include<stdlib.h>
struct Node{//结点结构体起手
int id ;//当前位置编号
int id ;
Node *next = NULL;
};

Expand All @@ -15,7 +15,7 @@ bool cut_next(Node *now,int move);
void Josephus(int n,int m,Node *head);
void special_Josephus(int n,Node *head);

Node * creat_and_prepare(int n){ //循环链表创建函数,并且每个结点的id为n-1
Node * creat_and_prepare(int n){
Node *head , *current;
head = (Node*)malloc(sizeof(Node));
current = head ;
Expand Down