Home
Blogs
Questions
Jobs
Monetize

Home

About Us

Blogs

Questions

Jobs

Monetize

Post Job

banner

Questions about grahams-scan

Read more about grahams-scan

python (65.2k questions)

javascript (44.3k questions)

reactjs (22.7k questions)

java (20.8k questions)

c# (17.4k questions)

html (16.3k questions)

r (13.7k questions)

android (13k questions)

Questions - grahams-scan

Can you pattern match integers to ranges in OCaml?

As part of Graham's Scan, I am writing a function that determines whether the line is turning left or right at a certain point. Considering we have a function determinant point -> point -> point...
test-img

ice-wind

pattern-matching

ocaml

grahams-scan

Votes: 0

Answers: 2

Latest Answer

No. Well... Conditional guards on patterns could do what you're suggesting. let turn t p s = let det = det s p t in if det < 0 then 'r' (* Turning right *) else if det > 0 then 'l...
test-img

Chris

Posts

Questions

Blogs

Jobs

The ultimate platform for coders and IT specialists

About

  • Company
  • Support

  • Platform

  • Terms & Conditions
  • Privacy statement
  • Cookie policy
  • Cookie option
  • OnlyCoders © 2025  |  All rights reserved