安洵杯2023misi部分wp

烦人的压缩包

直接下载压缩包

发现有密码,怀疑是伪加密

所以直接

java -jar .\ZipCenOp.jar .\+.zip

两个flag被修复

直接通过

跑出来密码

得到

一张图片,txt有提示图片里头有个zip包

直接foremost命令进行分离

发现里头有个flag,但是文件头被破坏了,直接修复09那一串

出现flag.txt

发现是okk!编码

直接解出flag

SYC{Yxx_Say_Thank3Q_v3ry_much}

sudoku_easy

用脚本解决数独问题

board = [
    [
9,0,0,0,0,0,8,4,0],
    [
0,0,6,7,0,0,0,3,0],
    [
8,1,0,2,0,4,0,0,7],
    [
0,0,7,1,2,8,0,5,4],
    [
1,8,9,4,0,0,2,0,0],
    [
0,2,0,0,9,6,0,0,1],
    [
0,0,1,0,6,0,0,2,0],
    [
6,5,2,0,0,3,0,7,0],
    [
0,9,0,5,0,2,3,0,6],
]


def print_board(board):
   
for i in range(len(board)):
       
if i % 3 == 0 and i != 0:
           
print("- - - - - - - - - - - - - - -")
       
for j in range(len(board[0])):
           
if j % 3 == 0 and j != 0:
               
print(end="")
           
if j == 8:
               
print(board[i][j])
           
else:
               
print(str(board[i][j]),end="")

def find_empty_square(board):
   
for i in range(len(board)):
       
for j in range(len(board[0])):
           
if board[i][j] == 0:
               
return (i, j)
   
return None

def
is_valid_move(board, num, pos):
   
# Check row
   
for i in range(len(board[0])):
       
if board[pos[0]][i] == num and pos[1] != i:
           
return False

   
# Check column
   
for i in range(len(board)):
       
if board[i][pos[1]] == num and pos[0] != i:
           
return False

   
# Check box
   
box_x = pos[1] // 3
   
box_y = pos[0] // 3

   
for i in range(box_y*3, box_y*3 + 3):
       
for j in range(box_x * 3, box_x*3 + 3):
           
if board[i][j] == num and (i,j) != pos:
               
return False

    return True

def
solve_board(board):
    find = find_empty_square(board)
   
if not find:
       
return True
    else
:
        row, col = find

   
for i in range(1,10):
       
if is_valid_move(board, i, (row, col)):
            board[row][col] = i

           
if solve_board(board):
               
return True

           
board[row][col] = 0

   
return False

print_board(board)
input("Press any key to start solving the puzzle...")
solve_board(board)

print("\nSolved Puzzle:\n")
print_board(board)

之后拿到shell,直接cat /flag

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值