• Home
  • About
    • Seokmin.Lee photo

      Seokmin.Lee

      Hello, I am a master's student in the Department of Convergence Security (Samsung Advanced Security) at Korea University.After graduation, I am expected as a security developer or researcher member of Samsung SDS.

    • Learn More
    • LinkedIn
    • Github
  • Posts
    • All Tags

[til][bj11663]선분위의점

16 Jan 2025

문제:

  • 제목: 선분위의 점
  • 링크 : https://www.acmicpc.net/problem/11663
  • 접근 방법 : 탐색

해결 방식:

import sys

sys.stdin = open('sample.txt')

input = sys.stdin.readline

N, M = map(int, input().split())

graph = list(map(int, input().split()))

for _ in range(M):
    start, end = map(int, input().split())

    near_idx_start = 0
    near_idx_end = 0

    for idx, search_value in enumerate(graph):
        if search_value == start:
            near_idx_start = search_value
        else:
            if search_value > start:
                near_idx_start = search_value[idx-1]





    near_idx =




PSPYTHONBJTIL항해 Share Tweet +1