---
layout: "default"
title: "Comparable"
description: "Swift documentation for 'Comparable': Instances of conforming types can be compared using relational."
keywords: "Comparable,protocol,swift,documentation,<,<=,==,>,>="
root: "/v2.2"
---

<div class="intro-declaration"><code class="language-swift">protocol Comparable</code></div>

<div class="discussion comment">
    <p>Instances of conforming types can be compared using relational
operators, which define a <a href="http://en.wikipedia.org/wiki/Total_or