# Testing word counting code using KLEE and CBMC

DevFeed: [Testing word counting code using KLEE and CBMC](<https://devfeed.tech/articles/testing-word-counting-code-using-klee-and-cbmc-20586.md>)

Original publisher: [Read original article](<https://yurichev.com/blog/wc/>)

Published: 2025-12-24T23:00:00Z

Content type: tutorial

Language: en

Sources: [Dennis Yurichev](<https://devfeed.tech/sources/dennis-yurichev.md>)

Topics: [Testing](<https://devfeed.tech/topics/testing.md>), [C](<https://devfeed.tech/topics/c.md>), [Code](<https://devfeed.tech/topics/code.md>), [Linux](<https://devfeed.tech/topics/linux.md>), [Unix](<https://devfeed.tech/topics/unix.md>)

Tags: [c](<https://devfeed.tech/tags/c.md>), [code](<https://devfeed.tech/tags/code.md>), [linux](<https://devfeed.tech/tags/linux.md>), [testing](<https://devfeed.tech/tags/testing.md>), [unix](<https://devfeed.tech/tags/unix.md>), [verification](<https://devfeed.tech/tags/verification.md>)

## AI overview

This article examines a rewritten word-counting exercise from The C Programming Language using buffer input instead of console input. It compares behavior involving zero bytes, whitespace, isolated words, and buffer limits with Linux's wc and the original Unix utility, then discusses verification with CBMC and KLEE and the feasibility of brute-force testing.

## Source excerpt

Testing word counting code using KLEE and CBMC