Judicial branch can check both legislative and executive branch by declaring laws as unconstitutional. For example, when Trump did the travel ban a federal judge was able to overturn it.
Legislative comes up or helps coming up with laws then sorta takes it to executive and judicial and if judicial deems it unconstitutional it vetos it judicial also enforces the laws.