• Transact Login
  • Litigate Login
  • Store Account
  • Customer Center
  • Support
logo
  • Solutions
    • Drafting
      • Litera Desktop
        An integrated experience with everything a lawyer needs to draft documents
      • Create
        Generate new documents and reduce manual entry
      • Check
        Analyze, proofread, and repair documents
      • Collaborate
        Compare complex documents and protect against metadata exposure
      • Publish
        Simplify your most complex PDF workflows and create text searchable PDFs
    • Workflow
      • Transaction Management
        A secure, collaborative deal management platform
      • Due Diligence
        AI/ML based solution to highlight and extract provisions automatically
      • Litigation
        A litigation management platform to connect all elements of your case
    • Firm Intelligence
      • Foundation Firm Intelligence
        Win more business and exceed client expectations
      • Pricing and Scoping
        Improve firmwide profitability and offer increased client transparency
      • Digital Marketing
        Manage and nurture your business relationships more effectively
      • Strategic Planning
        Connects your plans to everyday goals for outstanding results
      • Shipping and Invoice Management
        A single platform to manage a law firms shipping and invoice needs
      • Talent Management
        Streamline recruitment, CLE/continuing education management, performance reviews, and work allocation
      • Business Intelligence
        Retrieve, analyze, and visualize all financial data onto a highly configurable business intelligence dashboard
    • Governance
      • Governance and Collaboration
        Streamline collaboration through organized structures and access management
      • Business Continuity
        Ensure business continuity by always having access to data even during outage
      • Compliance
        Remain compliant with disposition policies by minimizing unnecessary data
      • Cloud Migration
        Kickstart your journey to the Cloud
      • Microsoft Teams Management
        Control data chaos and improve your Microsoft Teams security and governance
  • Customers
    • Who We Work With
    • Enterprise Law Firms
    • Small/Medium Law Firms
    • Corporate Solutions
    • Services
    • Case Studies
  • Company
    • Our Story
    • Management Team
    • Events
    • Partners
    • Press
    • Careers
    • Contact
  • Resources
    • Resource Library
    • The Changing Lawyer
    • LegalTech Matters Podcast
  • Login & Support
      • Transact Login
      • Litigate Login
      • Store Account
      • Customer Center
      • Support
Request a Demo Store

Why writing contracts is like writing code

On Tue 07 Dec 2021
Lawyers and programmers. Not many would argue these two job titles have much in common. In fact, the internet is pretty full of anecdotes saying lawyers don't understand technology or how to code. Well, at Clocktimizer, we know there area lot of tech savvy lawyers, but we also think that there's a lot of similarities between drafting a contract, and drafting code. In this blog we'll be looking at some of the ways contract definitions, and the lexicon of programming languages overlap. From the importance of precision, to why we all need to avoid infinite loops! For a more in depth look at the similarities between the fundamental structure of contracts and code, we highly recommend this blog by Joe Dewey, a partner at Holland & Knight.

The importance of definitions

If you've ever read through a contract you know that the first page or so is devoted to definitions. It's a fairly self explanatory step to create an understanding about specific terms. Better still, it avoids a lot of legal battles later as parties argue over whether or not the 'car' left to them by their Great Aunt Jane was the priceless Mustang or the Ford Fiesta. In law, these defined terms allow the rest of the contract to remain shorter and more readable. What many may not realise, is that this is very similar to the way a programming language works.Many programming languages, like Python or Ruby, use libraries to define specific actions ('statements'). These actions are often represented by a single word, which have been agreed upon in advance by the developers of the programming language. What they mean in practice, is that programmers can use a single word to dictate an action rather than writing out whole sentences in code. So, say a programmer wants to calculate the total cost of a 30-year mortgage with 5% interest. Instead of typing out the whole equation, they can simply type: calculate_total_mortgage_amount(30, 0.05). While this is a simple example, it is clear that there are parallels with contract drafting. In both, the point of definitions is to reduce the length of the document or code. Equally, it reduces uncertainty. In both cases, defining the terms, leads to a defined outcome.

Avoiding infinite loops

An infinite loop is a programming term, meaning a piece of code that lacks a functional exit. Often code will require the computer to change a piece of data. Following that change, a condition is checked. In many cases this could be whether a counter has reached a certain number. If this is not the case, the loop requires the computer to repeat the task, until the task times out (if a time is set) or until the computer runs out of memory and crashes. An infinite loop would then arise where the specific condition cannot be ascertained.While many lawyers may not be aware of infinite loops, they may have also fallen prey to them in defining the contract's terms. Eagle eyed readers may be able to spot the infinite loop in the following definition:
"Accounts Payable" means supplier invoices, reimbursements, expense payments and other line items that would typically fall within the scope of Accounts Payable;
Using the term you are defining, to define the term you are defining (whew - that was a tongue twister!) is the legal equivalent of an infinite loop. Both lawyers and programmers have to use precise definitions to avoid poor outcomes. Often, this involves both having to think about the desired outcome carefully, before committing those ideas to paper.

The sin of poor syntax

Every programmer will be painfully familiar with the error message. Errors in compiled code can arise from a myriad of syntax-based reasons. From a missing comma to a misspelled statement. The result is the same, however. The computer cannot 'read' and understand the code properly, and so the actions cannot be completed as desired.Syntax is equally important for lawyers in creating contract definitions. Contracts use capital letters to signify a defined term. It makes them easy to distinguish from undefined terms. Thus, a failure to use a capital letter can result in confusion for the contracting parties later. A common example is the word 'party'. 'Party' as defined in a contract refers to a specific person or persons (or even companies). However there can also be additional parties separate from the defined 'Party' referred to in the contract. A failure to use the capital letter in the right place, can result in a contract with an unintended outcome. For both lawyers, and programmers, syntax is essential.There is significant overlap between the way contract law and programming languages approach the function of language in both their fields. Language must be clearly defined to avoid confusion and reduce repetition. Lawyers and programmers must pay special attention to the way they define terms to achieve outcomes. Finally, both must pay close attention to syntax to create certainty for computers and contracting parties alike. So, if you're a lawyer and this blog sparks your interest in coding then don't forget to sign up to attend Legal Geek's annual conference in London in October. We'll be holding a free introductory coding class for all skill levels. See you there!

Posted in Foundation

Related Articles

Data driven pricing & a 360° view of your client work… in minutes

Webinar

Data driven pricing & a 360° view of your client work… in minutes

Scaling up Legal Project Management

Whitepaper

Scaling up Legal Project Management

Why operational excellence is more than just the latest legal buzzword

Blog

Why operational excellence is more than just the latest legal buzzword

A quick guide to data fallacies (and how to avoid them)

Blog

A quick guide to data fallacies (and how to avoid them)

logo
US: +1 630 598 1100 UK: +44 (0)20 3890 2860
Vision
  • One Vendor
  • Integration
Solutions
  • Litera Desktop
  • Litera Create
  • Litera Check
  • Contract Companion
  • Litigation Companion
  • DocXtools
  • DocXtools Companion
  • Litera Review
  • Litera SecureShare
  • Metadact
  • Litera Compare
  • Litera Transact
  • Kira Systems
  • Litera Litigate
  • Foundation Firm Intelligence
  • Clocktimizer
  • Concep
  • Objective Manager
  • PS/Ship
  • Prosperoware
Customers
  • Who We Work With
  • Enterprise Law Firms
  • Small/Medium Law Firms
  • Corporate Solutions
  • Case Studies
  • Services
Company
  • Our Story
  • Management Team
  • Events
  • Partners
  • Press
  • Careers
  • Contact Us
Resources
  • Resource Library
  • Webinars
  • The Changing Lawyer
  • LegalTech Matters Podcasts
logo
US: +1 630 598 1100 UK: +44 (0)20 3890 2860
  • Licensing Terms
  • Privacy Notice & DPA
  • Preference Center
  • Contact Us
  • Modern Slavery Statement

© 2023 Litera Corp. All rights reserved.