<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Sara Josepsdottir on Medium]]></title>
        <description><![CDATA[Stories by Sara Josepsdottir on Medium]]></description>
        <link>https://medium.com/@saradottir?source=rss-51ab70aa41f3------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*2IYG3yvshAtGP44dcn5diw.jpeg</url>
            <title>Stories by Sara Josepsdottir on Medium</title>
            <link>https://medium.com/@saradottir?source=rss-51ab70aa41f3------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 12:22:07 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@saradottir/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Sleepless Shenanigans: Laughing in the Face of Insomnia and Tips to Beat It!]]></title>
            <link>https://medium.com/@saradottir/sleepless-shenanigans-laughing-in-the-face-of-insomnia-and-tips-to-beat-it-48d297f0e159?source=rss-51ab70aa41f3------2</link>
            <guid isPermaLink="false">https://medium.com/p/48d297f0e159</guid>
            <category><![CDATA[health]]></category>
            <category><![CDATA[mental-health]]></category>
            <category><![CDATA[life-lessons]]></category>
            <category><![CDATA[self-improvement]]></category>
            <category><![CDATA[wellness]]></category>
            <dc:creator><![CDATA[Sara Josepsdottir]]></dc:creator>
            <pubDate>Sun, 22 Oct 2023 14:50:46 GMT</pubDate>
            <atom:updated>2023-10-22T14:50:46.129Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zANRQq__K5_u8VmM12lLfA.png" /></figure><p>Life can sometimes be a b**** and just when you need it the least, you tumble on the sidewalk and fall down face flat on the ground. That pretty much describes the turning point during my studies abroad. All jokes aside, these were tough times that pushed me to my limits.</p><blockquote>Insomnia isn’t just about being a night owl; it’s a serious condition that can turn your life upside down!</blockquote><p>I was a full time master student, living abroad in beautiful Copenhagen, Denmark. I was working part time as a research assistant at my university, 10–20 hours a week. In addition to that, I had to make sure I was eating well, exercising, and attending to my social life, not to mention dating *sigh*.</p><p>Well, let’s get to the point. My busy schedule didn’t give much time for relaxation, which is something I clearly needed, based on the physical symptoms I had. I got so stressed at one point my eye twitch didn’t stop for three days, THREE DAYS. My eye was practically Morse coding S.O.S. to anyone observant enough.</p><p>So, there I was, the embodiment of living, breathing, twitching stress. And just when I thought I had reached the pinnacle of stress, life introduced a new twist during a particularly gruesome school assignment. What started as a harmless survival tactic — trading sleep for study and regular caffeine infusions — quickly spiraled into an audition for the lead role in ‘Night of the Living Dead: The Academic Years.’ All jokes aside, I went a whole week sleeping 5 hours or less and boy, oh, boy, did I learn my lesson. The rivers of coffee I consumed couldn’t rally my brain the way I’d hoped, and with each sleepless night, it felt like my IQ was slowly being siphoned away.</p><h3>Enter: The Visit to the Doctor’s Office</h3><p>There I was, dragging my sleep-deprived, caffeine-overdosed, twitching body to the doctor’s office. I really thought I had tried everything. I begged the doctor to give me medication, anything that could help me fall asleep. I promised him I was not a drug addict, immediately regretting my idiotic joke as soon as it left my mouth. This was not the place to be funny.</p><p>This trip was not a success, and I ended up leaving the office with a flyer in my hand on “Gode råd mod stress” (or for the non-Danish among us, ‘Good Advice for Stress Relief’). Did I heed this sage advice? Absolutely not. In my stubborn head I had tried all of this a thousand times before. I just wanted a ‘quick fix’ to patch up my fraying insanity, preferably through medication *cough*.</p><h3><strong>Finally: How I Overcame My Insomnia</strong></h3><p>It wasn’t until I called my mom at 2 AM, tearfully accusing someone of stealing my kitchen towel — only to later find it in the fridge *loud sigh*— that I realized my lack of sleep had hit crisis level. That absurd event propelled me (or rather I was forced) to buy a flight straight to Iceland to see if the tranquility of home could provide me with the restorative sleep I needed. It was there where I finally left my stubbornness aside, and went on my journey to (almost) full recovery from insomnia.</p><h4>1. Seriously, Stop Scrolling: Put the Screens Away Before Bed!</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gGq6lurXZauPjctcwDAVSw.png" /></figure><p>Truly, a critical step forward was ditching screens at least an hour before bedtime. In the digital age, we’re programmed to scroll through our phones, binge late-night shows, or answer just ‘one more email.’ But breaking up with my screen each night before bed? That was the tough love my sleep schedule needed. It’s not just putting your phone down; it’s about resisting that glowing temptation to peek ‘just one more time.’ It’s a commitment, a ‘see you in the morning, dear phone’ kind of discipline. And honestly, it made all the difference.</p><p>At one point I just sat in bed and stared at a painting my parents picked (yes, I’m living with the folks again — still acclimating after my return from studying abroad). I got so relaxed (or just plain bored?) that I managed to fall asleep pretty quickly. However, there’s a catch; it’s essential to quiet the mind and listen to the sound around you — no planning the upcoming day, or the mountain of tasks you have ahead of you. Just you, the stillness, and the welcomed descent into sleep.</p><h4>2. Go to Bed Two Hours Before You Actually Plan on Falling Asleep</h4><p>This was a game-changer. I know it can be difficult saying no to that TV show you were so excited to watch, or going out for ice cream with a friend (or is that just an Icelander thing? — we literally do this all year round). BUT, hear me out here, desperate times call for desperate measures. Try dedicating just two weeks to this sleep experiment; it’s a small investment of time that could reveal a significant improvement in your sleep quality! Laying in bed forces your body to actually relax a bit. Engage in activities completely unrelated to screens or stress — like reading, journaling, or immersing yourself in a podcast or soothing music. I’ve found that downloading short meditation tracks is quite helpful, especially when I listen to them after putting down my book. This strategy also avoids the need to turn on your phone’s WIFI, sidestepping potential distractions from notifications etc.</p><h4>3. Going to Bed Hungry Can Keep You Awake — so Eat a Banana!</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*u1lxB6iPP34ShUAiLfaQbA.png" /></figure><p>People are stuck on intermittent fasting these days, and of course I joined the party. It was so extreme sometimes I ate my last meal at 5 PM and did not eat again until 11 AM the next day. What happens when you go to sleep too hungry, is that your body goes into survival mode, doing a lot of things to try to keep you awake, including racing thoughts, restlessness, and a heightened sense of alertness.</p><p>As an insightful article by my friend <a href="https://brooklynbedding.com/blog/the-insomnia-guidebook-troubleshooting-and-solutions-for-your-sleepless-nights">Brooklyn Bedding </a>points out: “…research has indicated that those who are dieting may have more interrupted sleep. Hunger pangs can actually wake you up, so grab a high-protein snack an hour or so before bed for a better night’s rest.” This nugget of wisdom became a part of my pre-sleep ritual, and it worked wonders in calming my mind before bed, which ultimately led me to falling asleep quicker. However, I ditched the protein, and ate a banana instead. As Mahammad Juber, MD elaborates on in his article on <a href="https://www.medicinenet.com/do_bananas_help_you_sleep_best_time_eat_one/article.htm">Do Bananas Help You Sleep</a>, these fruits are rich in magnesium and other components that are beneficial for our circadian rhythm. I also just love bananas, so if they are not your cup of tea, feel free to substitute with a healthy treat of your own.</p><h4>4. The Power of Reading</h4><p>This relates to point number 1. When I didn’t have my phone to endlessly scroll through, I had to find something else to keep my mind busy while lying in bed. And I started reading topics that I found exciting but not so as to keep me too engaged. For me, that sweet spot was books on famous physicists (yes, embrace the nerdiness!). Initially, I set a modest goal: read until I felt my eyelids grow heavy or until I’d reached the end of a chapter. Whichever came first would be my cue to close the book and close my eyes, inviting sleep to take over after a day of intellectual exploration.</p><h4>5. Finding Peace with Your Insomnia — Facing the Internal Storm</h4><p>This is sooo important. Numerous <a href="https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3181635/">studies</a> highlight the profound connection between anxiety disorders and insomnia. Acknowledging this fact helped me at least find peace with the fact that when my thoughts raced uncontrollably — like I had a whirlwind in my head — I learned to simply observe them and let them FLOW. It’s crucial to understand that suppressing your thoughts, particularly the disturbing ones, is counter-productive. Allowing them to simply pass through your mind acknowledges their presence without letting them anchor in your consciousness, reducing their power to disrupt sleep.</p><h4>6. Routine is Your Friend</h4><p>This points back to point number 2. For the first few weeks, dedicating two hours to winding down before bed can significantly help you in establishing a routine. However, the true game-changer is consistency — adhering strictly to this pattern. After this initial period, you might find you can reduce the wind-down time to just one hour. The key is that your body, over time, adapts to this schedule. It begins to recognize when it’s time to calm down and prepare for sleep, often leading to you naturally waking up for work or school without the need for a jarring alarm. It’s all about training your internal clock to work for you, not against you.</p><p>It’s important to establish a sacred ‘wind-down’ routine. This isn’t just about killing time before you sleep. It’s about crafting a pre-sleep ritual, a consistent set of activities that signal to your brain that it’s time to shift into ‘sleep mode.’ It could be taking a warm bath, having a cup of herbal tea, or reading a captivating book — choose actions that mentally and physically prepare you for rest. Consistency is key; your body craves predictability, especially when you’re reprogramming your sleep habits.</p><blockquote>Most importantly, be patient with yourself, and remember that healing is a process that often requires experimentation, introspection, and persistence.</blockquote><p>I could easily go on with another dozen tips, but then you would have gotten truly bored by now… I’m just glad you reached the end of the article *claps for you*.</p><p>Of course, these are just things that helped ME overcome my insomnia, and it’s not just one point that did the trick, it was a combination of these points and lots of trial and error. I sincerely hope this article sheds light on potential causes of your insomnia and provides you with effective strategies to help you beat this beast!</p><p>Love,</p><p><em>Sara.</em></p><p><strong>Feel free to leave more tips in the comments and give this article a clap if you found it useful!</strong></p><ul><li>For those interested in reading more about Insomnia, I found <a href="https://www.mayoclinic.org/diseases-conditions/insomnia/symptoms-causes/syc-20355167">this article</a> by <strong>MayoClinic</strong> very useful.</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=48d297f0e159" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Code Less, Accomplish More: How I use ChatGPT to Enhance my Programming Skills]]></title>
            <link>https://medium.com/@saradottir/code-less-accomplish-more-how-i-use-chatgpt-to-enhance-my-programming-skills-84e578442c88?source=rss-51ab70aa41f3------2</link>
            <guid isPermaLink="false">https://medium.com/p/84e578442c88</guid>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[chatgpt]]></category>
            <category><![CDATA[productivity]]></category>
            <dc:creator><![CDATA[Sara Josepsdottir]]></dc:creator>
            <pubDate>Sun, 22 Oct 2023 14:31:09 GMT</pubDate>
            <atom:updated>2023-10-22T14:31:09.225Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ywEHZZ_BSOdvTAq0" /><figcaption>Photo by <a href="https://unsplash.com/@freshvanroot?utm_source=medium&amp;utm_medium=referral">Rolf van Root</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Let me tell you, since <em>ChatGPT </em>entered the market, coding has been more fun than ever before. It isn’t just a tool, it’s the sidekick we didn’t know we needed. In this article, I am going to share some tips on how I use <em>ChatGPT </em>to make my life easier and, more importantly, to make me a better programmer!</p><p>Before we dive in, I have to note that I use <strong>ChatGPT Plus 4.0</strong>, which has significantly improved reasoning capabilities compared to the <strong>default 3.5</strong> model. If you’re a developer, a programming student, or in a related field, I highly recommend considering the subscription — it will make your life so much easier. That said, even the default model can prove useful with the right questions, though I advise always double-checking the answers for accuracy!</p><p><strong>1. Enhancing Code Readability</strong></p><p>Maybe not what you would have expected as a first point. However, I can’t emphasize enough about how important it is for code to be <em>readable</em>, especially when it comes to code that will be read by others, be it other developers or teachers at your university. As the teachers at my Python university course kept stressing: “You should always leave your code such that the next person that sees it can understand its purpose without having to run it.”</p><p>Questions I ask <em>ChatGPT</em> that help enhance my code’s readability:</p><ul><li>Can you make my code more readable? <em>— Here you can elaborate by saying:</em> For someone with limited understanding of code, etc.</li><li>Can you input comments where needed?</li><li>Can you name my variables something (more) descriptive?</li><li>Can you simplify my code?</li></ul><blockquote>Two very important points to be aware of here; always double check the response, and make sure that you preserve the original functionality of the code!</blockquote><p>Here’s a simple Python example where <em>ChatGPT</em> even included a doc string describing the function’s purpose:</p><pre>def CalculateAverageEvenNumbers(data):<br>    x = [i for i in data if i%2 == 0]<br>    y = sum(x)/len(x)<br>    return y</pre><p><strong>Question: </strong><em>Can you include a description of my function and add comments to enhance readability?</em></p><pre>def CalculateAverageEvenNumbers(data):<br>    &quot;&quot;&quot;<br>    Calculate the average of even numbers in a list.<br><br>    This function takes a list of numbers, extracts the even ones,<br>    and then calculates the average. If the list is empty or has no even <br>    numbers, the function will return 0 to avoid a division-by-zero error.<br><br>    Parameters:<br>    data (List[int]): A list of integers.<br><br>    Returns:<br>    float: The average of even numbers in the input list.<br>    &quot;&quot;&quot;<br><br>    # Extracting even numbers from the input list<br>    even_numbers = [number for number in data if number % 2 == 0]<br><br>    # Guard clause to handle empty lists or lists without even numbers<br>    if not even_numbers:<br>        return 0<br><br>    # Calculating the average of extracted even numbers<br>    average = sum(even_numbers) / len(even_numbers)<br><br>    return average</pre><p><strong>2. Optimizing for Efficiency</strong></p><p>I often get assignments at work where I have limited resources and thus my code has to perform fast and efficiently. It’s situations like these where even my seasoned googling skills hit a wall, especially under looming deadlines. I then turn to <em>ChatGPT </em>to help me with these coding-roadblocks.</p><p>On one such occasion, I was struggling with a data-intensive process that was painfully slow. The task was to analyze a large dataset, but doing this in a straightforward manner would take hours — time I didn’t have. I described my problem to <em>ChatGPT</em>, which suggested utilizing the ‘concurrent.futures’ module in Python. This module enables tasks to be executed concurrently using threading or multiprocessing, lowering execution time for data-intensive jobs.</p><p>Implementing this, the process that initially took hours was cut down significantly, optimizing my workflow. Not only did this save precious time, but it also expanded my coding toolkit, adding another layer of sophistication to my approach.</p><p><strong>3. Boosting Productivity with Single-Purpose Functions</strong></p><p><em>ChatGPT </em>has a good ability to generate functions that have one specific purpose, one responsibility. I use it to save time on creating functions for simple tasks and solutions for jobs that appear simple but are actually quite complex. For instance, I recently faced a seemingly innocent but brain-twisting task: looping through a list of points to find three that, when connected, formed the largest angle. This would involve me having to dive again into geometry and require a few minutes of my time not just to write the code, but also to ensure that it worked properly.</p><blockquote>With <em>ChatGPT</em>, it was like having a math whiz right by my side. I simply described my conundrum, and voilà — it offered a neat, elegant function precisely cut out for my needs.</blockquote><p><strong>4. Complex Problem Decomposition</strong></p><p>I am frequently confronted with complex coding problems where I have difficulty knowing where to start. In these cases I use <em>ChatGPT </em>to help me break down my task into manageable parts. The key point here is to paint a clear, detailed picture of your problem so <em>ChatGPT </em>grasps exactly what you need in the final solution.</p><p>Here’s how to kick things off:</p><ul><li><strong>State Your Case</strong>: Begin with the heart of the issue — what’s the problem you’re tackling, and why is it important?</li><li><strong>Envision Your Ideal Solution</strong>: Next, outline what the perfect outcome would look like. What’s your goal here?</li><li><strong>Set the Rules</strong>: Make a note of any constraints or specific conditions that your solution must meet.</li></ul><blockquote>ChatGPT is a learning experience in itself. With every interaction, I uncover new functions, explore unfamiliar libraries, and get more familiar with coding standards and best practices. This continuous exposure to diverse coding and solutions, along with the quick feedback, has definitely played a role in my quick development as a programmer.</blockquote><p>I hope these insights ignite your ideas on how to leverage our new AI friend, or at least, give you a head start!</p><h4>Feel free to share your own points in the comment section and leave a clap if you found this helpful!</h4><p><em>Until next time,</em></p><p>Sara</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=84e578442c88" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>