Showing posts with label Writing. Show all posts
Showing posts with label Writing. Show all posts

Tuesday, 21 June 2022

How to write a character who is smarter than you


We all have that one character (or few) who is significantly smarter than the writer. So, as a writer, how do you write such a character convincingly?

I can't claim to give you a formula for this or an answer that works every time. However, I have a lot of experience writing precisely these types of characters. This is probably also true of other mystery writers in general. I will share a few of my favourite tricks for pulling off highly intelligent characters convincingly.

1. Make them smarter in different ways.


A good example of this is Cassie from the short stories I've published here. No, Cassie isn't really smarter than me, or at least, not in every way. She is also somewhat immature. However, she does have a significant edge over me in a few things.

She is more observant, and her recall is mostly flawless. She is also willing to work on something that might not be very useful for a long time.

The thing is, all of this are qualities that can be faked on the page (or even in a comic book format) quite easily. As the writer, you will know which details are important and which details aren't, but the thing is, neither your characters nor your readers will have that knowledge. So when your character notices random things all the time, neither they nor the audience will know which of these are more important. You can also do this with details in the background for a visual medium. As long as you remember to put these details in / make it reasonably likely that your character observed them.

Then, when your character actually recalls the relevant information, it can look, well, impressive.

Of course, you can come up with other characteristics like this. A photographic memory helps. A character who observes people for fun will notice more than your average person. Depending on the genre you're writing, the characteristics that are useful will change.

2. Work backwards.


This can be a hit or a miss. 

If you know the ending, you're working with more context than your average character or reader. Therefore, your deductions, etc. will be more accurate. Having your character make these deductions would make them look really smart.

However, this is also very easy to mess up. First of all, you have to make sure that your character has all the information needed to make the particular deduction. You also have to be aware of the fact that the same information may be interpreted in different ways, so having your character acknowledge other possibilities would be a good idea. The problem here is that it's very easy to develop tunnel vision when writing something like this and completely fail to see alternative theories. 

Alpha readers and time can be your friends here. You can wait until you've forgotten the details of the story partially, but it can be a bit inconvenient, especially if you're a pantser like me (i.e. coming back and realising there's another possible explanation that your detective would have run with). Alpha readers are hard to come by. I really don't have an easy answer for this.

So what happens if you mess this up? The result is an explanation / deduction / theory that your character pulled out of their rear end. Or at least, that's what your readers will think. This will break your immersion completely, so use with caution.

In short, this is a high risk, high reward strategy.

3. Time is your friend.


You have hours to days to write or plan what your character must execute in minutes. Use that to your advantage. 

Your character may not have the luxury to document everything in the heat of the moment to discover patterns. You do. They may not have a full plan of their location. You can draw one and then sketch your plan there. They can't sleep on the problem, you can.

Once you've done that, have your character do all of that with less time / resources / etc. and they will look extremely smart. Of course, you should work with the information that the character would know or have a reasonable chance of knowing, otherwise you will risk breaking immersion.

4. Contrast


Contrasting your character against someone who isn't as smart is another good way to make them look intelligent. People generally interpret things relative to what's around it, so this can make your character look more intelligent by comparison. This is basically the Dr Watson to your Sherlock Holmes. 

So what if you have a lot of intelligent characters? Well, you can make them intelligent in different ways, which maintains the contrast, but highlights each character's capabilities relative to the others. This is especially useful if you have an ensemble cast, where everyone's supposed to be smart.

5. Have other characters tell the reader that a particular character is smart


This, admittedly, is a bit of a sneaky strategy and one that has to be used sparingly. You will also have to back this up with some proof occasionally. However, having other characters tell the reader that a character is intelligent (and treat them that way), particularly at their introduction, is a good way to form a particular impression in the minds of your readers.

However, you will have to back this up, especially if your character appears with any frequency or has an important role in the story. Otherwise, it will make the rest of your characters look less intelligent and possibly make the whole story frustrating. 

The advantage here is that you can take your time with showing your character's smarts. For example, you can introduce a character and then take your time with having them do something significant and smart. This will also come off an a payoff of a previous setup, which makes it even more satisfying.

6. Have your character's intelligence be of the sort that doesn't have to be demonstrated on the page


This is a fairly common approach, especially with scientist type characters. You can simply have them come up with gadgets, etc. with no explanation about how it was done, because frankly, most readers aren't interested in that. You can also add in a little technobabble to make it sound more convincing. 

This works, but I don't like this approach very much. Bad technobabble can be off-putting (I can't remember the number of times I've had to scream internally because they got the physics / engineering so wrong). 

A better approach would be to research the subject in question a little. You don't have to understand the maths (because you will have to deal with maths if you're going to study it in depth), but as long as you understand the general theory or study how experts talk about the subject to other people, you should have a reasonable starting point. Then you can go ahead and write about someone who created a supercar or space station without having to design one yourself.

Closing thoughts


These are not the only tricks you can use. If you have any, please put it in the comments! I'd love to hear about it and maybe have a discussion. 

Not all the tricks mentioned here are equally successful, and not all of them work for every intelligent character. You will have to decide what works for you (I know I say this in every writing related post but it's true). 

Hope this helps, and see you next time!



You can follow me on Facebook here and twitter here for updates.

Sunday, 1 May 2022

The man in black - chapter 2 (short story)

chapter 1 | chapter 3 | chapter 4


There was no doubt about it, this was a robbery. Jake appeared to have noticed what was going on as well, but Dany held his hand. He stopped. Lex and Bella stopped their discussion immediately. Cassie remembered that Bella was a bit serious about martial arts. Would she attack? Cassie didn’t know a lot about fighting, but the chairs were light, and she could use it as an emergency weapon if she had to be Bella’s backup.

Bella stood up. “Hey, is everything alright over there?” she asked.

The robber turned and pointed a pistol at them, while keeping the cashier in range as well. Cassie also saw the paper.

“Put all your money into the bag. Do not call the police.”

Pretty brazen, pulling this off in the middle of a crowded mall. All the cashier had to do was to stall. Someone would walk in. Unfortunately, the inside of the shop was not visible from all sides of the shop, due to a sticker on the glass, though they could see everything on the outside. There were also no cameras inside the shop.

The cashier continued stuffing the cash in the register into the bag. The waiter was also frozen on the other side of the counter. The robber folded the paper in two with one hand, displaying the message ‘hurry up’.

Was the pistol real? Cassie couldn’t tell – she had never seen a real one up close, and she suspected it was the same for the others with her. She didn’t dare move. The cashier finished stuffing all the money from the cash register into the bag. The robber grabbed the bag with one hand and backed out slowly, still aiming the pistol at them. Then, the robber turned and ran, straight through the mall.

Lex recovered first.

“After him!”

A look passed between him and Cassie. Both understood. Lex ran after the robber. Bella followed. Anna immediately placed a call to the police, as she was the only person from around there. Cassie walked up to the cashier. She had collapsed back into her chair. She looked shaken, but Cassie couldn’t afford to dawdle.

“Do you know who that was?”

The cashier shook her head. The waiter was also trying to take a call. Phil took his phone out of his shirt pocket. That was when Cassie noticed what he had done.

“Can you identify the guy?” asked Dany.

“I don’t think so,” said Phil, “you might be able to work out his skin tone around his ears and neck, but that’s about it.”

“Wasn’t wearing earrings,” said Cassie, “that might be useful. About average skin tone, couldn’t see whatever they were wearing under the coat, probably a man because those shoes would be odd on a woman, trousers were surprisingly baggy – will probably be thrown out. Average or slim build – hard to say. Height’s about 170 cm unless they were wearing lifts in their shoes. Did anyone smell perfume? Or deodorant or aftershave?”

Cassie looked at the cashier. She shook her head. That wasn't surprising, as most people wouldn't notice that unless the smell was offensive or they were wearing too much of it.

“The police is on the way,” said Anna.

Then Cassie’s phone rang. It was Lex. She answered.

“We chased him into the men’s bathroom,” said Lex, “I ran in, but dude had disappeared into a stall. The coat is on the floor, as is the hat. I don’t know which stall he ran into, but three stalls are occupied.”

“Where’s Bella?”

“She’s outside. She can’t come in here, can she?”

“Good point. The police are on the way, so try to hold them there. And stand guard outside the door because you won't stand a chance if it's not a one man job. We’ll join you as well.”

“I was about to do that. Bring the waiter or something. No one’s going to take a bunch of foreigners seriously.”

“Good point.”

Cassie, Jake, Dany, and Phil ended up leaving for the bathroom with the waiter, leaving just Anna and the cashier in the shop. The cashier agreed to close the shop immediately.

It took them a couple of minutes to get there. Bella was waiting outside, directing people away from the bathroom. Clearly, she wasn’t doing a good job of it. The waiter intervened immediately. Then a security guard joined them and helped them out once the waiter explained the situation. Jake and Lex went inside. The rest of them waited outside and kept others away from the scene. They heard arguing from the inside. The waiter went in as well. Cassie figured they were trying to detain those inside.

That was when the police arrived, along with Anna and the cashier. A police officer went inside immediately, and another, a woman, listened to their version of the story. Then the other policeman came out with three men in tow.

Two were wearing the same sort of shoes as the robber, Cassie noticed. Cassie didn’t think anyone would have a change of shoes with them. Shoes would be too bulky to hide under someone’s coat. If it had been in the bag, the cashier would have noticed it. It could have been hidden in the bathroom, but disposing of it once used would have been a problem.

Cassie also noticed that none of the men were dressed like the robber. Sure, the hat and coat were discarded. The gloves and mask could have been cut up and flushed. That was possible with the bag as well, as it was a drawstring bag. The trousers – well, that would be on the possible side, as they didn’t look too thick either. It would be more difficult to flush the sunglasses. There was a problem with this strategy though, as Cassie was sure that flushing that much fabric would create an epic clogging problem.

So where were the rest of the clothes?

There was another problem. Build and height wise, any of these three men could have been the robber. Cassie had hoped that would give the robber away immediately, but clearly, they had no such luck.

The policeman asked the security guard to lock that bathroom. Then he turned to the cashier.

“I’m Mark. Can you tell me your name?”

“Liv,” she answered.

“Alright, let’s go talk somewhere else. You too, Ed.”

The two employees of the shop followed him away. The other officer turned to the three suspects.

“Alright. Let’s go sit on a bench over there. Please tell me all about yourselves. I’m Selene, by the way.”

The first to speak was a man of about average height, wearing a beige short-sleeved shirt and a dull green cap./

“Darrell. I’m a painter, here to buy supplies. I’m not very successful or well known.”

The next to speak looked almost like a teenager. He was wearing a grey polo shirt, blue jeans, a baseball cap and fairly plain sneakers. He also wore glasses, but they didn’t look too powerful. Cassie couldn’t help noticing the dark circles under his eyes.

“Adam. I work at the laptop repair shop that’s over there.”

Looking at him more closely, Cassie judged it was likely. He was the sort of guy who didn’t really look his age. Or maybe he really was barely older than a teenager but a genius with laptop repairs.

The last to speak was wearing a light polo shirt and black jeans. He, too, wore glasses.

“Hal. I’m a freelance writer. I’m moderately successful. I mostly write online.”

Cassie could see they had their work cut out for them. All three men had the same height and build. All three had short black hair. All three had about the same skin tone. Their voices were different, but the robber hadn’t said a word during the robbery. And if their shirts were seen by an eyewitness, well, their shirts were about the same colour too.


END OF CHAPTER TWO

Previous chapter: chapter 1

Next chapters: chapter 3 | chapter 4

You can also follow me on Facebook here.

Until next time!

Sunday, 24 April 2022

The man in black - chapter 1 (short story)

chapter 2 | chapter 3 | chapter 4

Cassie laughed.

“Yeah, that’s the most likely answer!”

“Sure, laugh!” said Anna, “I’m not sure it was technically in the syllabus!”

Cassie was in a small café in the mall near their university. The semester was over, and many of them would be heading home for the next month. That is why they had gone there for a movie, some gift shopping, and to have some fun with friends before that.

“Can we talk about something that’s, you know, not subject related?” asked Jake, “for example, which film are we watching?”

“There are a few good options,” said Dany, Jake’s girlfriend and newest addition to their group, “Okay, two as far as I am concerned. What about the rest of you?”

Phil had the website of the theatre up on his phone. “Boring romance, comedy, with huge inverted commas around 'comedy', not in English, not in English, superhero, action movie, and super serious awards bait. Dany’s right, there are only two options.”

“You can go watch the awards bait,” said Lex, “it might help you catch up on some sleep.”

“Very funny,” said Phil, “seriously, which one shall we watch?”

Cassie noticed a huge stack of boxes at the counter of the coffee shop. Probably some sort of order, she thought. There were two employees in the shop, and they were stacking it there. Cassie expected someone would come pick it up.

By now, the shop was almost empty except for them. That was no wonder, as they were a little past teatime. Most people would start having dinner. Cassie wondered who would be ordering stuff from a café at this time. Maybe it was for a party. That sort of made sense, especially if they’d be having dinner at late at night.

Anna sipped her coffee. “Let’s pick one when we get there. What do we do about food? Smuggle it in, or buy popcorn?”

“Eat once it’s over?” asked Dany, “it’s less illegal, somehow. They don’t want you smuggling food it because it stinks.”

“She’s got a point,” said Phil, “but I’m not buying popcorn. Seriously, why isn’t this a watch party at one of our rooms again?”

“Never occurred to anyone?” asked Cassie.

A pair of men came into the café. Cassie noticed they were dressed somewhat formally, but fancily. It was a party, probably some sort of minor cooperate event, thought Cassie. They started talking with the cashier. The waiter went out to get a trolley. Cassie could see why that would be needed. The car park was not that far away, but it was a lot of boxes.

“Let’s have a bit of a snack before the movie starts,” said Phil, “we have at least an hour to kill as it stands because someone’s idea of shopping was, well, strangely efficient.”

“I don’t like shopping, that’s why I made a list,” said Dany.

“Not judging you. Just an observation.”

“So, order some sandwiches?” asked Jake.

They all looked at each other, and a few of them nodded. Jake went up to the counter and placed the order. Just then, the waiter returned with a trolley. Cassie admired his self-control. She would have used it as a skateboard.

Both employees and the two men who came with them were kept busy filling up the trolley. The seven of them sipped their drinks slowly, trying to decide on a film, which then drifted into debate/ discussion about a previous film. Cassie hadn’t watched it, so she let Phil, Lex, and Bella debate it. The trolley was filled up, the men paid in cash, and they wheeled the trolley out. The waiter followed them, presumably to help them load it into a vehicle.

The waiter returned a few minutes later. He collapsed on a chair behind the counter. The cashier went into the kitchen. Cassie assumed it was to make the sandwiches they had ordered.

Outside, the mall was fairly crowded. The shop was a little glass island in the middle of the mall. There was a speciality food shop a little way away. It was way out of their price range. There was a couple of branded clothes shops. There was also a bookshop. Cassie wanted to go in there, in a way, but buying physical books didn’t make a lot of sense given her current living situation.

Cassie had her work cut out for her over the break. She had decided to go home for two weeks. The air ticket was expensive, but she wouldn’t have a chance to go home over the next summer because of her internship, which meant it was now or never. Going home would probably mean a trip, lots of food, and buying lots of stuff to bring back. On the other hand, she would not get any work done during that time, and she really wanted to practice what she had learned that semester, at least to stay in touch with things.

She had her sandwich mostly in silence as the discussion turned into a full-blown debate between Bella and Lex. She spent her time studying those around her. The couple sitting at the next table sat up. They finished and then paid the bill. They were dressed well. Possibly a date, Cassie decided. There was another man sitting alone at a table, staring at his phone and inhaling coffee. He wouldn’t be there long either, thought Cassie. He desperately needed to be awake for something, probably work of some sort given how he was scrolling through something on his phone.

The man stood up, as Bella launched into a tirade about a scene in the film they were talking about and how it illustrated her point. He paid the bill, and left. Their group was the only one left in the café. It wasn’t an issue, as there was a couple of hours to the displayed closing time.

Then someone walked in. Cassie sat up immediately. This person was wearing a long coat – a weird choice given the climate – as well as a black hat and a black mask, with dark sunglasses. They were also carrying a plain black drawstring bag and wearing gloves. Cassie couldn’t tell anything more about them other than their height – roughly in the 170 cm range – and the fact that they were wearing regular shoes most men would wear to work. Also, their hair was black and a little longer than shoulder length, but that was likely a wig.

Cassie stiffened. She nudged Dany, who was seated next to her. Phil, too appeared to have noticed what was happening.

Then, this person unfolded a piece of paper from their coat pocket and displayed it to the cashier. Cassie noticed her eyes widen.

Cassie realized it immediately – the shop was being robbed, and they were in the way if anything were to happen.



END OF CHAPTER ONE

Next chapter: chapter 2 | chapter 3 | chapter 4

You can also follow me on Facebook here.

Until next time!

Monday, 11 April 2022

The Cipher - Chapter 4 (short story)



After the snack break, they got back to work again. Cassie looked at the program Phil had created. It was at a higher level than she would have programmed, but she understood what it did. She looked at the snippets again.

There was no way the divisible by four thing was accidental. This cipher worked in pairs of hexadecimal numbers. It could be the Playfair cipher, but that would be hard to crack. No, that couldn’t be. Dany wouldn’t expect Jake to crack that. It was doable, but it would require a considerable amount of subject knowledge and a lot of maths. She couldn't expect Jake to convince someone else to do it for him either.

It had to be much simpler. Especially if, as she suspected, it had something to do with Jake’s upcoming birthday. That would be completely consistent with Dany’s character.

Unless it really was Playfair and the keyword was something significant to the two of them. If that was the case, they were doomed. There was no way Jake could recall something like that, and they'd all be caught in the crossfire.

Cassie pushed it to the back of her mind. The Playfair thing would be a last resort. No, she had to think simpler. What if two hexadecimal characters represented one letter? Sure, it was wasteful, but it would work.

How would she do that?

The most obvious would be adding the two characters followed by modulus 26. Cassie decided to try modifying the program on her own.

This took a bit of time. She had Phil’s code as a starting point, but she still had to look stuff up. After messing with it for about ten minutes, she ran the code. Immediate syntax error.

Cassie was used to this. She checked the code and realised she had missed a single quotation. She fixed that and ran the code. It spit out a result for the first message.

VLLIXIHXUETNONBRZMBNQWHGJWDGMNKSLRRFQOCJMMIEXPMAPPKZJOQXQHQZOXXMFQPWOTDWAUNAIUCVNKBNGNWFYWGUZANGWKTLELOXJECRZLLAA

That didn’t look better than anything else they had so far.

Cassie leaned back in her chair.

She thought for a moment. Then she remembered what they had attempted before the snack break. She could try other alphabets, such as including a space, including numbers, special characters, all of that. Now that the code was set up, it was child’s play. She ran it with just letters and space first, so that it would have 27 possible characters.

I CAN ARRANGE SOMETHING AT THE MALLTHE CAFE ON THE SECOND FLOOR DOES PARTIESYOUR JOB IS TO LURE HIM THERE SOMEHOW

So that was it. It was absurdly simple. You just added the adjacent hexadecimal numbers, found the remainder when it was divided by 27, and matched it to A-Z and zero. There were no keys, nothing. The really clever part was a sort of randomness built into the code that would fool most traditional code breaking approaches. 

She had to be friends with Dany.

Cassie forced herself down to earth again. She looked across at Jake. He was on his phone, smiling at something. He was still distracted. He hadn’t seen her reaction. Good.

She put the next message in, line by line this time.

STOP STRESSING ABOUT IT
EVEN IF HE SUSPECTS SOMETHING HE WONT REALLY KNOW UNTIL THE DAY
CAN YOU THINK OF A WAY TO INVITE HIS FRIENDS WITHOUT ALERTING HIM

Both looked like messages to Dany from someone. Cassie copied the next message into the code.

JUST TELL CASSIE OR ANNA
YOU WERE IN THE SAME CLASS IN THE FIRST YEAR WERENT YOU
ANYWAYS I DIDNT BOOK CAFE
STUDY AREA WILL DO AS YOU SAID

Yep, this was definitely Dany’s way of inviting them to the party. Cassie nudged Phil and showed him the results she had copied into a document. She also typed in “don’t tell Jake, it’s about his birthday party,” under it very quickly. He understood. She nudged Lex and showed him the document. He nodded. Anna was staring at her laptop, so there was no way to get the message to her without alerting Jake.

Phil took a look at her code quickly. Then he stopped the decoding program he was running and started creating a program to do the ciphering. It took him some time. He was in the middle of this when Jake looked up.

“Any results yet?”

Cassie quickly collapsed the run panel on her IDE so that Jake wouldn’t be able to see the decoded answer, even if he walked over and looked at her screen.

“Not yet, but we might be getting warmer,” said Lex, “this might take a bit of time.”

“So, what cipher is it?” asked Jake.

“Playfair, probably,” said Cassie, quickly, “that seems statistically likely.”

“So are we looking at a long solving time?” asked Jake.

“Yeah, there’s a lot of possibilities, in the tens of thousands if my maths is correct,” said Phil, “I need to concentrate.”

“Okay,” said Jake. He returned to his phone.

Meanwhile, Cassie looked up Jake’s birthday. It was the next day. Well done, Dany, she thought, well done.

Cassie watched as Phil typed in the code as fast as he could. Cassie had some idea about what Phil would do. He was trying to write a reply to Dany.

It took him a few tries to get it to compile without errors, and two more tries to generate a proper message that Cassie could decode. Finally, he generated a message and sent it to Cassie.

d2783b90471d752cd54cfe32cd7b5b4690a56d39bd48a12e56166e8bc44ead2aa39c992c32966fc5e6ae8638c54d0848c88f47b37c2adc431e01
1dcaf1909e5da00de12c5435950d179d298b1496dc0031a6c366692b441a5c9794af8919fb050ab6aecbf7a904368fcc

Cassie decoded it.

GOT THE MESSAGE WILL BE THERE
PHIL CASSIE ANNA AND LEX

Cassie nodded. So did Lex.

Phil sent the ciphered message to Dany.

Lex stretched like a cat.

“Look, this is going to take a while,” he said, “wouldn’t it be better if Phil ran this overnight?”
“Good point,” said Phil, quickly.

Anna looked up.

“You sure it’s Playfair?”

“Pretty sure,” said Cassie,

“Okay, let’s meet again tomorrow then,” said Anna, “Jake?”

“Yeah, let’s do that.”

They all went their separate ways after that. Phil messaged her afterwards with a ciphered message from Dany. She checked it. It was Dany simply confirming it. She was about to reply when Phil sent another message saying he decoded it already.

The next day, Cassie showed up at study area on time. Dany had informed them that she’d bring Jake along after all. Phil had managed to keep Jake at bay by telling him that they had to consider another alphabet for Playfair and that they were all working on it remotely.

That was how they managed to surprise Jake completely.

After they cut the cake and had a bit of a party, Dany finally came clean about the cipher.

“So wait, you were using it to plan a birthday party?”

“Affirmative,” said Dany, “and I used it to send a message to them as well.”

“You were in the know the whole time?” asked Jake.

“Nah, we cracked it, realised what was going on, and messaged her.”

“So, when did you really crack it?” asked Jake.

“Yesterday,” said Phil, “when Cassie said she was sure it was Playfair.”

“And you’ve all been lying to me since then? And I had no idea?”

“Basically,” said Lex, “Hey, it was for a good cause.”

“Show me the messages.”

Cassie showed him the translations. Jake read the messages over and over a few times.

“How did you know it wasn’t a kidnapping?” he asked.

Cassie rolled her eyes. “First, the sender, Dany, doesn’t have the social skills to organise a kidnapping, no offense, Dany. Secondly, that’s an incredibly insecure cipher for one, and thirdly, no kidnapper would basically send us an invitation to the same place, and fourth, I remembered your birthday was on the day we had our end-term party last year. Is that a satisfactory explanation?”

Jake pinched the bridge of his nose and shook his head. He was clearly trying to not laugh. 

“Yes, it is satisfactory, unless someone was planning to kidnap all of us.”

“From within the university where everyone is recorded at the entrance?” asked Dany.

“Good point,” said Jake, “So, have I introduced two groups of cipher nuts to each other?”

Cassie looked at Dany, and Dany looked at Cassie. Dany nodded.

“Yup,” said Cassie.


------------------------THE END ------------------------



Read previous chapters: chapter 1  | chapter 2 | chapter 3

Thank you for reading! I hope you found this interesting.

Next week will be the code for this cipher, for enciphering and deciphering. Stay tuned for that.

The week after that, Cassie and co will tackle a real crime. Stay tuned for that!


You can also follow me on Facebook here.

Until next time!

Monday, 4 April 2022

The Cipher - chapter 3 (short story)

chapter 1  | chapter 2 |  chapter 4

Cassie decided to sleep on the problem. She knew that helped with some problems, particularly when she was stuck on assignments. Her dreams that night were filled with hexadecimal numbers and all sorts of ciphers, but she slept well regardless.

She spent the morning doing other stuff. After all, Phil wasn’t going to be up until midday anyway, and they didn’t have lectures that week. They had one coursework presentation, and then next week, they’d be free to leave the campus.

She had lunch and watched some stuff just because. She was halfway through it when her phone rang. It was Jake, who wanted to meet in the study area for a cipher cracking session. He promised snacks, and Phil had agreed to come. Cassie had no objections to that.

She joined the others there. Phil’s ridiculously powerful laptop was running, and currently, it sounded a bit like a hairdryer. He looked up when he saw Cassie.

“No results so far. How about you?”

“Same. Any new leads?”

“Nope.”

Cassie put her laptop bag on the table. “I’ve been thinking, like, should we change our approach?”

Phil gave her a quizzical look. Cassie took it as an invitation to continue.

“Well, how would you encipher something if you wanted to communicate with someone in secret?”

Phil thought for a second. “I’d use a proper cipher algorithm.”

“No, if you couldn’t do that?”

“Why would that be difficult? Vigenere with an easy to remember, ridiculously long key,” he replied, “Do you know it’s theoretically unbreakable if the key is as long as the message?”

True, and if that was the case, there was no way they were breaking it. Cassie turned to Jake.

“What about you?”

“I’d type it in windings.”

“Forget I asked. Anna?”

“Same? Or maybe A=1, B=2, and so on. That’ll be easy to break though.”

“It’s extremely easy,” said Cassie, “seriously, guys, can’t any of you think of an original approach?”

“Maybe if given time,” said Phil, “all that’s required for a cipher to work is that it takes some texts and spits out unintelligible text at the other end, which can be translated to the original text at the receiving end. Ideally, you wouldn’t lose any information in the process. Or introduce ambiguity because languages are a mess as is”

Cassie nodded. “But additional information would be okay.”

“Absolutely,” said Phil, “but it’ll be wasteful.”

“Wouldn’t be a problem if you’re not putting it on the internet, or dealing with large volumes,” said Cassie.

Phil nodded. “So you’re saying this cipher might be a bit wasteful.”

“I’m just considering possibilities.”

“Like skip codes?” asked Anna, “what if you ciphered a skip code the traditional way?”

“Yep, that could work,” said Phil, “I’ll try that on the text we translated the way Cassie suggested.”

“Assignments?”

Everyone turned. It was Lex, a fourth year.

Jake told him what was going on. He immediately volunteered to help. He, too, sat down with his computer, which he had with him for some reason.

“The skip code idea has some merit,” said Lex, “but it’s a bit basic, don’t you think?”

“Hey, not everyone remembers resistor codes, let alone using them for a random cipher,” retorted Cassie.

“Look, I detest econ with my entire being. I simply wanted some sense of normalcy, hence I defaulted to what I liked, what I was comfortable with, and did not include weird interest calculations…”

“So you’re saying we need to find what Dany likes?” asked Anne.

“Easy,” said Jake, “she reads / watches a lot of mystery-related stuff. She is also absolutely obsessed with fantasy as a genre. She loves programming and solving silly little problems that most people would do with pen and paper. She is very good at maths and enjoys it. She is organised in a chaotic way. She has also developed an obsession with fermented food recently for some reason and I think I’m catching it too. I think that’s it.”

“Fermented food?” asked Anna.

“Yeah, that’s the least relevant thing, let’s focus on that,” said Lex, “though seriously, liking maths and programming for the hell of it sounds more relevant to me. This suggests something simple but effective. Such as a Vigenere cipher.”

“Exactly, thank you!” said Phil, “we’re not going to crack this.”

Cassie rolled her eyes. She turned to Jake. “You said she’s weirdly happy about this situation. What sort of happy is she?”

Jake shot her a blank look.

“Is she the evil-I-have-fooled-you happy or is she just super giggly?”

“Well, she has been giggling a lot and I haven’t seen an evil witch look on her, so…”

“That means we can break this! Don’t you see? She wants us to break it,” said Cassie, “that means it’s a breakable cipher, or at least she thinks it is, which is not always the same thing, there was this once time….”

“Alright, so you’re saying it’s not Vigenere?” asked Phil.

“No, I’m saying it’s breakable even if it is Vigenere,” said Cassie.

“Alright, I’ll try that next,” said Phil, “once this is done trying what it’s trying right now. No results so far though.”

Cassie looked at the numbers again. It was a groups of four. Then another idea struck her.

“What if it’s Playfair, but converted to hex and she’s added a random multiple of 26 on top to fool us? That would definitely work.”

“Actually, that would,” said Phil, “but we’ll have research about breaking a Playfair cipher then.”

“Why 26?” asked Anna, “why are you assuming it’s just letters? She could have added numbers and spaces and special characters and all of that.”

“Normally you’d replace spaces with an Z before you cipher it,” said Lex, “and you’d avoid special characters and spell out any numbers.”

“But what if she didn’t?” asked Cassie, “how obsessed is she with ciphers, Jake?”

“Based on other people in my life, about average, I guess?”

“So she likely knows about that trick,” said Lex, “and she’d use it unless she plans to talk about pizza a lot….”

"She does like pizza," said Jake.

“You could replace it with an X,” Cassie pointed out.

“True,” said Anna, “but what if she chose not to? If she added just space, it’s going to be 27 characters. If it’s upper and lower case letters, it’s 52, plus space, it’s 53. If you add numbers, it’s 62 or 63. I think we should try all of that.”

“Easy enough,” said Phil, “so, did you guys do any programming?”

“A bit of micro c, python, java…” started Cassie.

“Perfect. Can I burrow your computer? I’ll just code that quickly.”

“Sure.”

“Dark mode IDE. I see you are a woman of culture, Cassie.”

Cassie bit back a retort. Sure, she didn’t have a good sleep schedule, but she didn't think Phil could look at a light mode anything for more than ten minutes at this point.

Phil produced the first output in a few minutes.

“This is A-Z plus space.”

KZA LSEX OUGWFZTJIMPUURQORDXMGP LBLUHMRRKZRXGAISMPTAEWTABGEAXDAMFWUSXPILI AENNPODYVLF MOSXPZBZTAAHCCKQASZGQNUVPZCBOMVLWQGIUVZTJRBCWTROASHTTXFWLGSBBHVKRBNLSXFPYUYCBI PIUPLUPEOLPBSZQYCFGHNXVCCOMFCSRTUTHNGOUVKFMAEEWBRYRUTYHDEP UC

“This doesn’t make a lot of sense,” said Lex.

Phil was typing away furiously.

“And this is with upper and lower case, no spaces.”

QffgNYjZgrzjWLZyJlOqYvRWSwJEvGRauFmampVsQAyyGbMUrsuCGxAGBllCfFdpLaxUyTnsKgdlooqtieAmiaQOWbqZgGVfIHIhtrhSAjYqvVudIiQrAqevGIaXAXRVcdxTXSAWPZTAFYoItHimdKsiuovZLRYxFIcIHunaTNxqGQqPcWbvDdmImNdXGhUMoItRZUALVjOxCMLMfEfzeyaRaZDiehVFxd

“That’s objectively worse,” said Lex.

“And this is with upper and lower case and space.”

NcddMVhYdqxiWIZwJkNqWvRTQuGArGQaqDmXkoTsN vyGbKTpruBFxxDBjiBbEcoIYwTyRlpJdciooqrgbymhaOOUZqZeCUdEHFfpreS iUpvVsbFfPpyoatGIXW VNTcdxTUQAULWTzFXnHtEfkZKsfrnuYIQYwBFcIDslXRMwqFPoPcUatAdjHkNaWEfRMkFtRWUxJRiOwzLIMdEfydvZRXWAiegSCwd

“And this is with numbers.”

u9J C2NO gdYWpZcJaDqCvR07anXDGGaCum4Qe su0RyGb1JVhu26xTkBPE2y5SepEmJy8RL  SEooqXM8emXa5OAFqZKZKJbHmLBrAS0YrfvVYHmBFVeUxZGI4M0Bk cdxT17AAi3TpFNd8tlBQwKsBNdkOpGYmYmcIaYR48Cmq6FUPcAQZhdF8QN7MvLyM7mtR3UT0oYOmVBpMJEfoTRPR43hieWzjmd

“None of them make sense,” said Lex.

“Well, something has to,” said Cassie, “Unless this is a convoluted ploy by Dany distract you, Jake.”

“Why?”

Was it a significant day to the two of them? Say, the day they met each other? Not according to what Cassie could remember, unless they were already dating before they joined the university. That was unlikely as their nationalities were different. What about Jake’s birthday? That was possible. She remembered going out for a term end / birthday party last year, so that was entirely possible. But then, Jake should have realised that.

“You can figure out if that’s the case,” said Cassie, “unless you have any other pertinent information that may help us…”

“Seriously, does anyone have any ideas?” asked Lex.

“Snack break talking about something else?” asked Anna, quickly, “like which movie we are watching on Friday?”

That made sense. The group decided to have a snack break. As promised, Jake bought snacks. Phil’s laptop still sounded like it was preparing for take-off. They spent a few minutes chatting about other stuff.


END OF CHAPTER THREE

Read previous chapters: chapter 1  | chapter 2 
Next chapter: chapter 4

Thank you for reading! Do let me know if you manage to crack the cipher. It doesn't need a key, and the stuff they've figured out so far might give you a few clues. (hint: it's straightforward, but not a common cipher algorithm).

You can read more about the Vigenere Cipher here if you're interested. The cipher in question here is not a Vigenere Cipher though.

The next chapter will be uploaded next Monday, 11th April.


You can also follow me on Facebook here.

Until next time!


Monday, 28 March 2022

The Cipher - chapter 2 (short story)

 chapter 1  | chapter 3 | chapter 4


The computer finished booting up. Cassie opened up the browser to get the code into her computer. She checked her emails too, just in case. There was an email with no subject from Phil. Typical.

“Not ASCII, not UTF in any form unless special characters are supposed to mean something, no other common type of encoding I can think of. I’ll check if it’s something super obscure.”

Cassie had been afraid of that. She copied the numbers into a ciphertext to a text file and looked at it.

acbb87bc41b48b4dbc5f9b5716a7199a0959422a802f11b27a98a5d4ff06451afe6d26b68e5d7d2cac34ce32061b744893602e363a31d0a2018dc136ef39515da7826548327b

8fc83ebc51c128282a958aba9c26561a780e7e832a1988d64987d807a489fd2bbd123457e85e2f159685a4be44939c92ee970608b64b347fe17d1c1d3113b37a007edfb51368054c5c3c2da3be8eed0a2cbe

ca5c634da7451865d5a41c08d7968fb67b41652a3a44920f1c7e4f979f1dc23c8e0db94b6e89b00cf8a42d11b514d073e5570e65d240a70c87041f6752ce4e11b6b59f221e55b1a1651d

First things first, she had to find the length of the lines. This was easy enough. She wasn’t going to count it manually – not with this many numbers to count. Instead, she let her word processor do it for her. 140, 164, and 148, counting it line by line. Cassie noticed right away that all these numbers were even. No, not just that. They were divisible by four. That was the largest common factor. This made it very likely that she would have to look at sets of four numbers, which was four hexadecimal digits, or two bytes.

Cassie typed this out in response to Phil and sent it.

The next step, then, was to split the text into groups of four.

acbb 87bc 41b4 8b4d bc5f 9b57 16a7 199a 0959 422a 802f 11b2 7a98 a5d4 ff06 451a fe6d 26b6 8e5d 7d2c ac34 ce32 061b 7448 9360 2e36 3a31 d0a2 018d c136 ef39 515d a782 6548 327b

8fc8 3ebc 51c1 2828 2a95 8aba 9c26 561a 780e 7e83 2a19 88d6 4987 d807 a489 fd2b bd12 3457 e85e 2f15 9685 a4be 4493 9c92 ee97 0608 b64b 347f e17d 1c1d 3113 b37a 007e dfb5 1368 054c 5c3c 2da3 be8e ed0a 2cbe

ca5c 634d a745 1865 d5a4 1c08 d796 8fb6 7b41 652a 3a44 920f 1c7e 4f97 9f1d c23c 8e0d b94b 6e89 b00c f8a4 2d11 b514 d073 e557 0e65 d240 a70c 8704 1f67 52ce 4e11 b6b5 9f22 1e55 b1a1 651d

With that, she had to look for repeats. She couldn’t spot any. This meant she couldn’t attack it with statistical analysis.

What if the order of numbers didn’t matter? If the order mattered, 4 hexadecimal digits would give 43680 possibilities. Very few languages had that many characters. If order didn’t matter, it would be 1820 possible combinations. That was still way too much for most languages. Besides, almost every group of four in this cipher was completely unique. That was way too many combinations for English, at least.

No, this had to be simpler.

She looked at her mails again. There was one from Jake. It was another cipher.

“Dany sent this to my phone just now. She’s enjoying herself thoroughly.”

fe3dab0a1169be5f0a97f14ac7ab3e90756740c5cb1fe9994d9857bdaecba9b6bda371757d8acd544229f359a081

84a9e142604651af01bb551fc2519974be57193caa4812515b25768f86100817cc954a86df5ca01ca4101580d04a896e8863f15a06024d7d0a8383392e7bd83a737f9a8afa07dd8f3c282165745add506e345b52a6222b3e4808c76c4a65f7251b9de9c68483a228a0664712796ac215717a3fbbe29c0998f105044d9f1b

115d417cfa57bebb524d9488e7563bd2dfc9a936d1b1588d7a83d81a48b950215a62c49bd4c0b91a93966c84841dfbc85b04ffcb6497c9be933f9e4252cfbc8ce93ff1abf8c0c62482a641b71e7a6311a3399d2d2e7730ba1dd56439f671c4931d0578a4c35f6b2f0e783db6c8bdb641956f98895f81b9b3432fda9f09a0fe18994b

 

That was a lot of text. Cassie checked the number of characters in each line again. 92, 252, 260. Again, all of them were divisible by four. This had to mean something.

Just then, she got another email from Phil.

“Converting them to denary numbers as is makes no sense, I’m afraid.”

That should have been obvious. The email continued.

“We were taught a little bit about encryption so I’m going to try to apply some of the common encryption algorithms to this problem and see if it makes a difference. Might be limited without a key though, and it's entirely possible it's theoretically impossible to crack in a reasonable time. It’ll take a while, but I’ll automate it.”

That would be possible, yes, and Phil would do the job better than anyone. He would likely to find the answer too – Dany was a computer science student like him, so she likely had the same sort of knowledge base to start with. After all, that was how she broke Lex’s puzzle a week ago – Cassie was already familiar with the things he used as keys in that puzzle. In this case, well, Phil had that advantage.

Staring at it wasn’t giving Cassie any ideas. She watched something instead. Actually, she did that for a couple of hours, went out to buy something for dinner, returned to her room, and watched something again for another hour while having dinner. Then she opened the computer again. There was an email from Phil.

“Put everything together, program is running. So far, I’m not seeing any results. Will nap while it runs. Ciao.”

Typical Phil. He had the ability to nap anywhere at any time, and as usual, he put it to full use.

Cassie stared at the numbers again. There was no flash of inspiration at once. Then it struck. Would it be just modulus 26 like with all regular ciphers? That was entirely possible. Also, everything being divisible by 4 could be a huge coincidence.

Or maybe it was padded out that way on purpose.

Cassie tried the numbers pair by pair.

The first pair, ac would translate to 172 in denary numbers. The remainder when divided by 26 was 16. Q was the 17th letter in the alphabet, or number 16 when starting from zero. This would still make sense.

The next, BB, gave the answer 5. That was a problem – 5 corresponded to F. There were no words that started with QF as far as Cassie knew. She decided to try another pair for good luck. The next pair, 87, gave 5 again. QFF? The next pair gave G. QFFG. This was not good, unless it was a double layered cipher of some sort.

Anyway, she could try to translate this my hand, or she could use Phil to do the translation for her. This was precisely the kind of thing he was good at. She dropped him an email and tried to find something to watch. She found nothing. She checked her emails just in case, and Phil’s answer was there.

QFFGNYJZGRZJWLZYJLOQYVRWSWJEVGRAUFMAMPVSQAYYGBMURSUCGXAGBLLCFFDPLAXUYTNSKGDLOOQTIEAMIAQOWBQZGGVFIHIHTRHSAJYQVVUDIIQRAQEVGIAXAXRVCDXTXSAWPZTAFYOITHIMDKSIUOVZLRYXFICIHUNATNXQGQQPCWBVDDMIMNDXGHUMOITRZUALVJOXCMLMFEFZEYARAZDIEHVFXD

That made absolutely no sense, but it was sufficient for a frequency analysis at the very least.

The distribution did not look too bad, but it didn’t look too hopeful either.

There was another email from Phil. “Cassie, this doesn’t look like a simple substitution cipher, the distribution of letters is all wrong. My program is still running and it hasn’t caught anything yet either.”

He probably reached that conclusion by some form of statistical analysis. He knew what he was doing, but Cassie wasn’t quite ready to give up yet.

Then, Jake sent yet another cipher.

226e8d44288c80bc87352674536e677c59a56f9efd9a37866534acaab75f467bbb0144bd9e9c16a6f237606a8560a914

83a3dac99938cec60412262f73ac8b6cfe2a102e45a0a0014306ad4d48af2828491af74ddb094363a667308fc008e6941e605a90dcd3b9aeb77fad963b0e4eac3eb951bcd574d823458946895e3cdb9e1836b908bb536a644f37de971921b915c037b9987e6d1b5044401ec8ad75

bb6e55c6b05b8683a533f72f7590ae7a2c7e635938373509eaaee0c2cdc00daf2f59f4ca053fa705eca8729eef1fb876d939

42c3e9a44988d839bd9fe777559e4e4a4f0631a7024e953e997dd90a1f226521cfae237200357d9100cf1373f34ebc452a716755707a45ae726e5619

 

The lengths of the lines in this were again 96, 220, 100, 120. Again, all of these were divisible by four. This could not be a coincidence. This had to mean something.

Could it be a four-digit number in hexadecimal? No way. That was way too much information for a letter of English. As far as Cassie knew, Dany spoke neither Chinese nor Japanese, or any other language that would need so many characters. Okay, it was possible is was an abugida, either a South Asian or South East Asian language, counting letters and vowel marker combinations as letters, but that surely wouldn’t take more than three hexadecimal digits.

In short, Cassie was completely stumped.

Then Cassie received another email. She checked it.

“Dany suspects I’ve already given the cipher to all of you. She’s in an extremely good mood for some reason. It’s great, but it’s also a little weird because I can’t make head or tail of the situation. You will have to crack it. My reputation depends on it. I’ll bring snacks and give you moral support.”

Typical Jake. But right now, she could do with snacks and moral support.



END OF CHAPTER TWO

Read previous chapters: chapter 1

Next chapter: chapter 3 | chapter 4

Thank you for reading! Do let me know if you manage to crack the cipher (hint: It doesn't require a key). The next chapter will be uploaded next Monday, 4th April.


You can also follow me on Facebook here.

Until next time!


How to write a character who is smarter than you

We all have that one character (or few) who is significantly smarter than the writer. So, as a writer, how do you write such a character con...