The document discusses parsing context-free languages and proposes a new abstraction called Grammar Flow Graphs (GFGs) to represent grammars. GFGs model grammars as control flow graphs where parsing problems become path problems. This representation unifies different parsing techniques and allows them to be viewed based on dimensions of non-determinism, lookahead, and context. The document provides an example GFG and discusses how GFGs can be used to represent Earley's parsing algorithm.
This document discusses closure properties of regular languages under various operations. It proves that regular languages are closed under union, concatenation, Kleene star, reversal, complement, and intersection by constructing non-deterministic finite automata (NFAs) to recognize the languages resulting from these operations. Examples are provided to illustrate the constructions of NFAs for union, concatenation, Kleene star, and reversal. The document also discusses using DeMorgan's laws to show closure under complement and intersection.
The document discusses shift-reduce parsing and LR parsing methods. It covers:
- Shift-reduce parsing corresponds to a rightmost derivation using shift and reduce actions. Handlers are substrings that match production right-hand sides.
- Shift-reduce conflicts are resolved by favoring shift, while reduce-reduce conflicts favor the first production.
- An LR parser uses a DFA to determine the shift and reduce actions based on the state and next input symbol. This resolves conflicts.
- The states of the DFA correspond to LR items with the dot in different positions. Transitions are determined by goto and closure operations.
Compiler Components and their Generators - LR ParsingGuido Wachsmuth
The document discusses traditional parsing algorithms used in compiler construction. It covers predictive parsing algorithms and LR parsing algorithms, which can parse LL(k) and LR(k) grammars respectively. LR parsing uses parse tables that are generated from LR(0) items, closures and goto functions. The document also mentions LR parse table generation and the SLR and LALR algorithms.
This is a presentation on LALR parser. This presentation was created by 6th sem CSE student.
LALR parser is basically used to creating the LR parsing table. LALR parser is used because it is more powerful than SLR and the tables generated by LALR consumes less memory and disk space than CLR parser.
Bottom-up parsing builds a derivation by working from the input sentence back toward the start symbol S. It is preferred in practice and also called LR parsing, where L means tokens are read left to right and R means it constructs a rightmost derivation. The two main types are operator-precedence parsing and LR parsing, which covers a wide range of grammars through techniques like SLR, LALR, and LR parsing. LR parsing reduces a string to the start symbol by inverting productions through identifying handles and replacing them.
2024 State of Marketing Report – by HubspotMarius Sescu
https://www.hubspot.com/state-of-marketing
· Scaling relationships and proving ROI
· Social media is the place for search, sales, and service
· Authentic influencer partnerships fuel brand growth
· The strongest connections happen via call, click, chat, and camera.
· Time saved with AI leads to more creative work
· Seeking: A single source of truth
· TLDR; Get on social, try AI, and align your systems.
· More human marketing, powered by robots
ChatGPT is a revolutionary addition to the world since its introduction in 2022. A big shift in the sector of information gathering and processing happened because of this chatbot. What is the story of ChatGPT? How is the bot responding to prompts and generating contents? Swipe through these slides prepared by Expeed Software, a web development company regarding the development and technical intricacies of ChatGPT!
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
The realm of product design is a constantly changing environment where technology and style intersect. Every year introduces fresh challenges and exciting trends that mold the future of this captivating art form. In this piece, we delve into the significant trends set to influence the look and functionality of product design in the year 2024.
This document discusses closure properties of regular languages under various operations. It proves that regular languages are closed under union, concatenation, Kleene star, reversal, complement, and intersection by constructing non-deterministic finite automata (NFAs) to recognize the languages resulting from these operations. Examples are provided to illustrate the constructions of NFAs for union, concatenation, Kleene star, and reversal. The document also discusses using DeMorgan's laws to show closure under complement and intersection.
The document discusses shift-reduce parsing and LR parsing methods. It covers:
- Shift-reduce parsing corresponds to a rightmost derivation using shift and reduce actions. Handlers are substrings that match production right-hand sides.
- Shift-reduce conflicts are resolved by favoring shift, while reduce-reduce conflicts favor the first production.
- An LR parser uses a DFA to determine the shift and reduce actions based on the state and next input symbol. This resolves conflicts.
- The states of the DFA correspond to LR items with the dot in different positions. Transitions are determined by goto and closure operations.
Compiler Components and their Generators - LR ParsingGuido Wachsmuth
The document discusses traditional parsing algorithms used in compiler construction. It covers predictive parsing algorithms and LR parsing algorithms, which can parse LL(k) and LR(k) grammars respectively. LR parsing uses parse tables that are generated from LR(0) items, closures and goto functions. The document also mentions LR parse table generation and the SLR and LALR algorithms.
This is a presentation on LALR parser. This presentation was created by 6th sem CSE student.
LALR parser is basically used to creating the LR parsing table. LALR parser is used because it is more powerful than SLR and the tables generated by LALR consumes less memory and disk space than CLR parser.
Bottom-up parsing builds a derivation by working from the input sentence back toward the start symbol S. It is preferred in practice and also called LR parsing, where L means tokens are read left to right and R means it constructs a rightmost derivation. The two main types are operator-precedence parsing and LR parsing, which covers a wide range of grammars through techniques like SLR, LALR, and LR parsing. LR parsing reduces a string to the start symbol by inverting productions through identifying handles and replacing them.
2024 State of Marketing Report – by HubspotMarius Sescu
https://www.hubspot.com/state-of-marketing
· Scaling relationships and proving ROI
· Social media is the place for search, sales, and service
· Authentic influencer partnerships fuel brand growth
· The strongest connections happen via call, click, chat, and camera.
· Time saved with AI leads to more creative work
· Seeking: A single source of truth
· TLDR; Get on social, try AI, and align your systems.
· More human marketing, powered by robots
ChatGPT is a revolutionary addition to the world since its introduction in 2022. A big shift in the sector of information gathering and processing happened because of this chatbot. What is the story of ChatGPT? How is the bot responding to prompts and generating contents? Swipe through these slides prepared by Expeed Software, a web development company regarding the development and technical intricacies of ChatGPT!
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
The realm of product design is a constantly changing environment where technology and style intersect. Every year introduces fresh challenges and exciting trends that mold the future of this captivating art form. In this piece, we delve into the significant trends set to influence the look and functionality of product design in the year 2024.
Lesson 12 - The Blessed Hope: The Mark of the Christian.pptxCelso Napoleon
Lesson 12 - The Blessed Hope: The Mark of the Christian
SBS – Sunday Bible School
Adult Bible Lessons 2nd quarter 2024 CPAD
MAGAZINE: THE CAREER THAT IS PROPOSED TO US: The Path of Salvation, Holiness and Perseverance to Reach Heaven
Commentator: Pastor Osiel Gomes
Presentation: Missionary Celso Napoleon
Renewed in Grace
Unleash your spiritual growth journey as a truth-seeker!
Learn More:
👉https://tkg.tf/4D
Tracking "The Blessing" - Christianity · Spiritual Growth · Success
Do you ever feel like your Bible highlighting isn't quite enough to ignite lasting spiritual growth? Have you struggled to retain key takeaways from your Bible study sessions?
Discover how living in 4D can transform your highlighting into a strategic tool for spiritual development.
Learn More:
👉https://tkg.tf/4D
In this video, you'll gain insights on:
How highlighting key verses and themes can enhance memory and retention of Scripture (we see a few key ones, here!)
Studies have shown that highlighting can significantly improve information recall. Highlighting key points visually reinforces them in your mind, leading to better long-term memory.
How to personalize your Bible study through strategic highlighting. Don't just highlight everything!
This video will teach you how to strategically highlight based on what resonates with you, focusing on central themes, recurring ideas, or connections between different passages.
Watch More:
👉https://tkg.tf/4D
How connecting highlighted passages can reveal deeper biblical truths. By highlighting these connections, you can see the bigger picture and uncover the underlying messages within Scripture.
By the end of this video, you'll be equipped to unlock the hidden potential within your highlighted Bible and embark on a transformative spiritual growth journey! Don't forget to like and subscribe for more inspiring content on deepening your faith.
Note: For Christians seeking to enrich their Bible study and deepen their faith, as well as any other spiritual seeker of truth and growth.
Learn More:
👉https://tkg.tf/4D
New York City love spells in Dallas, TX.spellshealer8
Get ex back TX (+256) 789- 682- 081 Love spells in Houston, TX Astrologer Psychic near me to remove negative energy. Protection spells by Spell Caster | Love Spells | Black Magic | the witchcraft. Black magic expert and voodoo love spells that work overnight to retrieve that love | Best Psychic in Houston with powerful voodoo to renew your relationship & make your relationship stronger. love spells to bring back the feelings of love for ex-lovers.
https://spellshealer8.wixsite.com/binding-powerful-los
Increase the intimacy, affection & love between you and your lover using voodoo relationship love spells in USA. money spells, easy love spells with just words, think of me spell, powerful love spell, spells of love, spells that work, love potion to attract a man, easy love spells with just words, pink candle prayer, white magic spells, call me spell, manifestation spell, gay love spells, Commitment spells, business spells and, how to bring back lost love in a relationship, Witchcraft love spells that work immediately to increase love & intimacy in your relationship. Attraction love spells to attract someone, stop a divorce, prevent a breakup & get your ex back.
REUNITE WITH AN EX LOVER IN 72 HOURS
If your lover is gone, don't be desperate anymore! You are a few clicks away from a prompt resolution of your problem: We will our spiritual powers to bring him/her back. This service has been the reason of so many happy endings that you should consider it as a serious solution. Let us show you our method with zero chances of rejection. Don't waste your precious time; get your lover back NOW!
MAKE HIM/HER LOVE ME
You love someone but this isn't mutual? Don't wait for the deluge and make him or her love you now. This service will create a great alchemy between this person and you. In just a few weeks, you can make the person you dream of falling in love with you. We recommend you to combine this service with a Marriage ritual if you want this person to commit you.
BREAK UP A RELATIONSHIP
The perfect service to break up a relationship you don't think legitimate. Your lover has gone with someone else? You love someone but this person is already involved in a relationship? Don't hesitate to break them up as this ritual and prayer is very powerful and will give very good results in a few weeks only.
STOP A DIVORCE NOW
Your husband or you wife is thinking about divorce but you don't want this to happen? Order this service now to reinforce the bonds of your relationship and save your marriage. This service will make him/her realize that a divorce would be a mistake and will strengthen love and passion. With permanent results, this service will guarantee a long lasting marriage and will make you happy.
FAITHFULNESS
Your partner cheats on you? This love ritual is definitely the one you need! Your lover will dream about you every night and will realize the pain you have been suffering since he/she
LOVE CHARMS
I DO ALL THE FOLLOWING SPELLS
*Binding Your
Astronism, Cosmism and Cosmodeism: the space religions espousing the doctrine...Cometan
This lecture created by Brandon Taylorian (aka Cometan) specially for the CESNUR Conference held Bordeaux in June 2024 provides a brief introduction to the legacy of religious and philosophical thought that Astronism emerges from, namely the discourse on transcension started assuredly by the Cosmists in Russia in the mid-to-late nineteenth century and then carried on and developed by Mordecai Nessyahu in Cosmodeism in the twentieth century. Cometan also then provides some detail on his story in founding Astronism in the early twenty-first century from 2013 along with details on the central Astronist doctrine of transcension. Finally, the lecture concludes with some contributions made by space religions and space philosophy and their influences on various cultural facets in art, literature and film.
Tales of This and Another Life - Chapters.pdfMashaL38
This book is one of the best of the translated ones, for it has a warning character for all those who find themselves in the experience of material life. Irmão X provides a shrewd way of describing the subtleties and weaknesses that can jeopardize our intentions, making us more attentive and vigilant by providing us with his wise pages, reminding us between the lines of the Master's words: "Pray and watch."
Lucid Dreaming: Understanding the Risks and Benefits
The ability to control one's dreams or for the dreamer to be aware that he or she is dreaming. This process, called lucid dreaming, has some potential risks as well as many fascinating benefits. However, many people are hesitant to try it initially for fear of the potential dangers. This article aims to clarify these concerns by exploring both the risks and benefits of lucid dreaming.
The Benefits of Lucid Dreaming
Lucid dreaming allows a person to take control of their dream world, helping them overcome their fears and eliminate nightmares. This technique is particularly useful for mental health. By taking control of their dreams, individuals can face challenging scenarios in a controlled environment, which can help reduce anxiety and increase self-confidence.
Addressing Common Concerns
Physical Harm in Dreams Lucid dreaming is fundamentally safe. In a lucid dream, everything is a creation of your mind. Therefore, nothing in the dream can physically harm you. Despite the vividness and realness of the dream experience, it remains entirely within your mental landscape, posing no physical danger.
Mental Health Risks Concerns about developing PTSD or other mental illnesses from lucid dreaming are unfounded. As soon as you wake up, it's clear that the events experienced in the dream were not real. On the contrary, lucid dreaming is often seen as a therapeutic tool for conditions like PTSD, as it allows individuals to reframe and manage their thoughts.
Potential Risks of Lucid Dreaming
While generally safe, lucid dreaming does come with a few risks as well:
Mixing Dream Memories with Reality Long-term lucid dreamers might occasionally confuse dream memories with real ones, creating false memories. This issue is rare and preventable by maintaining a dream journal and avoiding lucid dreaming about real-life people or places too frequently.
Escapism Using lucid dreaming to escape reality can be problematic if it interferes with your daily life. While it is sometimes beneficial to escape and relieve the stress of reality, relying on lucid dreaming for happiness can hinder personal growth and productivity.
Feeling Tired After Lucid Dreaming Some people report feeling tired after lucid dreaming. This tiredness is not due to the dreams themselves but often results from not getting enough sleep or using techniques that disrupt sleep patterns. Taking breaks and ensuring adequate sleep can prevent this.
Mental Exhaustion Lucid dreaming can be mentally taxing if practiced excessively without breaks. It’s important to balance lucid dreaming with regular sleep to avoid mental fatigue.
Lucid dreaming is safe and beneficial if done with caution. It has many benefits, such as overcoming fear and improving mental health, and minimal risks. There are many resources and tutorials available for those interested in trying it.
The Book of Samuel is a book in the Hebrew Bible, found as two books in the Old Testament. The book is part of the Deuteronomistic history, a series of books that constitute a theological history of the Israelites and that aim to explain God's law for Israel under the guidance of the prophets.
2nd issue of Volume 15. A magazine in urdu language mainly based on spiritual treatment and learning. Many topics on ISLAM, SUFISM, SOCIAL PROBLEMS, SELF HELP, PSYCHOLOGY, HEALTH, SPIRITUAL TREATMENT, Ruqya etc.A very useful magazine for everyone.
Trusting God's Providence | Verse: Romans 8: 28-31JL de Belen
Trusting God's Providence.
Providence - God’s active preservation and care over His creation. God is both the Creator and the Sustainer of all things Heb. 1:2-3; Col. 1:17
-God keep His promises.
-God’s general providence is toward all creation
- All things were made through Him
God’s special providence is toward His children.
We may suffer now, but joy can and will come
God can see what we cannot see
Heartfulness Magazine - June 2024 (Volume 9, Issue 6)heartfulness
Dear readers,
This month we continue with more inspiring talks from the Global Spirituality Mahotsav that was held from March 14 to 17, 2024, at Kanha Shanti Vanam.
We hear from Daaji on lifestyle and yoga in honor of International Day of Yoga, June 21, 2024. We also hear from Professor Bhavani Rao, Dean at Amrita Vishwa Vidyapeetham University, on spirituality in action, the Venerable BhikkuSanghasena on how to be an ambassador for compassion, Dr. Tony Nader on the Maharishi Effect, Swami Mukundananda on the crossroads of modernization, Tejinder Kaur Basra on the purpose of work, the Venerable GesheDorjiDamdul on the psychology of peace, the Rt. Hon. Patricia Scotland, KC, Secretary-General of the Commonwealth, on how we are all related, and world-renowned violinist KumareshRajagopalan on the uplifting mysteries of music.
Dr. Prasad Veluthanar shares an Ayurvedic perspective on treating autism, Dr. IchakAdizes helps us navigate disagreements at work, Sravan Banda celebrates World Environment Day by sharing some tips on land restoration, and Sara Bubber tells our children another inspiring story and challenges them with some fun facts and riddles.
Happy reading,
The editors
Lição 12: João 15 a 17 – O Espírito Santo e a Oração Sacerdotal | 2° Trimestr...OmarBarrezueta1
Esta lição é uma oportunidade para discutirmos um assunto multo mal interpretado no contexto cristão, que é o fato de algumas pessoas pensarem que o conhecer Jesus é ter a nossa vida mudada em todas as áreas, como se Deus tivesse o dever de transportar-nos deste mundo para um outro mundo onde muitas coisas maravilhosas que desejamos seriam reais. No entanto, a nossa fé não nos tira do mundo após nos convertermos; ao invés disso, permanecemos vivendo sob as mesmas circunstâncias. O propósito de Deus não é nos tirar do mundo, mas nos livrar das ações do maligno (Jo 17.15), Sendo assim, a vida eterna não significa estar fora da realidade deste mundo, mas conhecer o único Deus verdadeiro (Jo 17.3).
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
Mental health has been in the news quite a bit lately. Dozens of U.S. states are currently suing Meta for contributing to the youth mental health crisis by inserting addictive features into their products, while the U.S. Surgeon General is touring the nation to bring awareness to the growing epidemic of loneliness and isolation. The country has endured periods of low national morale, such as in the 1970s when high inflation and the energy crisis worsened public sentiment following the Vietnam War. The current mood, however, feels different. Gallup recently reported that national mental health is at an all-time low, with few bright spots to lift spirits.
To better understand how Americans are feeling and their attitudes towards mental health in general, ThinkNow conducted a nationally representative quantitative survey of 1,500 respondents and found some interesting differences among ethnic, age and gender groups.
Technology
For example, 52% agree that technology and social media have a negative impact on mental health, but when broken out by race, 61% of Whites felt technology had a negative effect, and only 48% of Hispanics thought it did.
While technology has helped us keep in touch with friends and family in faraway places, it appears to have degraded our ability to connect in person. Staying connected online is a double-edged sword since the same news feed that brings us pictures of the grandkids and fluffy kittens also feeds us news about the wars in Israel and Ukraine, the dysfunction in Washington, the latest mass shooting and the climate crisis.
Hispanics may have a built-in defense against the isolation technology breeds, owing to their large, multigenerational households, strong social support systems, and tendency to use social media to stay connected with relatives abroad.
Age and Gender
When asked how individuals rate their mental health, men rate it higher than women by 11 percentage points, and Baby Boomers rank it highest at 83%, saying it’s good or excellent vs. 57% of Gen Z saying the same.
Gen Z spends the most amount of time on social media, so the notion that social media negatively affects mental health appears to be correlated. Unfortunately, Gen Z is also the generation that’s least comfortable discussing mental health concerns with healthcare professionals. Only 40% of them state they’re comfortable discussing their issues with a professional compared to 60% of Millennials and 65% of Boomers.
Race Affects Attitudes
As seen in previous research conducted by ThinkNow, Asian Americans lag other groups when it comes to awareness of mental health issues. Twenty-four percent of Asian Americans believe that having a mental health issue is a sign of weakness compared to the 16% average for all groups. Asians are also considerably less likely to be aware of mental health services in their communities (42% vs. 55%) and most likely to seek out information on social media (51% vs. 35%).
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
Creative operations teams expect increased AI use in 2024. Currently, over half of tasks are not AI-enabled, but this is expected to decrease in the coming year. ChatGPT is the most popular AI tool currently. Business leaders are more actively exploring AI benefits than individual contributors. Most respondents do not believe AI will impact workforce size in 2024. However, some inhibitions still exist around AI accuracy and lack of understanding. Creatives primarily want to use AI to save time on mundane tasks and boost productivity.
Organizational culture includes values, norms, systems, symbols, language, assumptions, beliefs, and habits that influence employee behaviors and how people interpret those behaviors. It is important because culture can help or hinder a company's success. Some key aspects of Netflix's culture that help it achieve results include hiring smartly so every position has stars, focusing on attitude over just aptitude, and having a strict policy against peacocks, whiners, and jerks.
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
PepsiCo provided a safe harbor statement noting that any forward-looking statements are based on currently available information and are subject to risks and uncertainties. It also provided information on non-GAAP measures and directing readers to its website for disclosure and reconciliation. The document then discussed PepsiCo's business overview, including that it is a global beverage and convenient food company with iconic brands, $91 billion in net revenue in 2023, and nearly $14 billion in core operating profit. It operates through a divisional structure with a focus on local consumers.
Content Methodology: A Best Practices Report (Webinar)contently
This document provides an overview of content methodology best practices. It defines content methodology as establishing objectives, KPIs, and a culture of continuous learning and iteration. An effective methodology focuses on connecting with audiences, creating optimal content, and optimizing processes. It also discusses why a methodology is needed due to the competitive landscape, proliferation of channels, and opportunities for improvement. Components of an effective methodology include defining objectives and KPIs, audience analysis, identifying opportunities, and evaluating resources. The document concludes with recommendations around creating a content plan, testing and optimizing content over 90 days.
How to Prepare For a Successful Job Search for 2024Albert Qian
The document provides guidance on preparing a job search for 2024. It discusses the state of the job market, focusing on growth in AI and healthcare but also continued layoffs. It recommends figuring out what you want to do by researching interests and skills, then conducting informational interviews. The job search should involve building a personal brand on LinkedIn, actively applying to jobs, tailoring resumes and interviews, maintaining job hunting as a habit, and continuing self-improvement. Once hired, the document advises setting new goals and keeping skills and networking active in case of future opportunities.
A report by thenetworkone and Kurio.
The contributing experts and agencies are (in an alphabetical order): Sylwia Rytel, Social Media Supervisor, 180heartbeats + JUNG v MATT (PL), Sharlene Jenner, Vice President - Director of Engagement Strategy, Abelson Taylor (USA), Alex Casanovas, Digital Director, Atrevia (ES), Dora Beilin, Senior Social Strategist, Barrett Hoffher (USA), Min Seo, Campaign Director, Brand New Agency (KR), Deshé M. Gully, Associate Strategist, Day One Agency (USA), Francesca Trevisan, Strategist, Different (IT), Trevor Crossman, CX and Digital Transformation Director; Olivia Hussey, Strategic Planner; Simi Srinarula, Social Media Manager, The Hallway (AUS), James Hebbert, Managing Director, Hylink (CN / UK), Mundy Álvarez, Planning Director; Pedro Rojas, Social Media Manager; Pancho González, CCO, Inbrax (CH), Oana Oprea, Head of Digital Planning, Jam Session Agency (RO), Amy Bottrill, Social Account Director, Launch (UK), Gaby Arriaga, Founder, Leonardo1452 (MX), Shantesh S Row, Creative Director, Liwa (UAE), Rajesh Mehta, Chief Strategy Officer; Dhruv Gaur, Digital Planning Lead; Leonie Mergulhao, Account Supervisor - Social Media & PR, Medulla (IN), Aurelija Plioplytė, Head of Digital & Social, Not Perfect (LI), Daiana Khaidargaliyeva, Account Manager, Osaka Labs (UK / USA), Stefanie Söhnchen, Vice President Digital, PIABO Communications (DE), Elisabeth Winiartati, Managing Consultant, Head of Global Integrated Communications; Lydia Aprina, Account Manager, Integrated Marketing and Communications; Nita Prabowo, Account Manager, Integrated Marketing and Communications; Okhi, Web Developer, PNTR Group (ID), Kei Obusan, Insights Director; Daffi Ranandi, Insights Manager, Radarr (SG), Gautam Reghunath, Co-founder & CEO, Talented (IN), Donagh Humphreys, Head of Social and Digital Innovation, THINKHOUSE (IRE), Sarah Yim, Strategy Director, Zulu Alpha Kilo (CA).
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
The search marketing landscape is evolving rapidly with new technologies, and professionals, like you, rely on innovative paid search strategies to meet changing demands.
It’s important that you’re ready to implement new strategies in 2024.
Check this out and learn the top trends in paid search advertising that are expected to gain traction, so you can drive higher ROI more efficiently in 2024.
You’ll learn:
- The latest trends in AI and automation, and what this means for an evolving paid search ecosystem.
- New developments in privacy and data regulation.
- Emerging ad formats that are expected to make an impact next year.
Watch Sreekant Lanka from iQuanti and Irina Klein from OneMain Financial as they dive into the future of paid search and explore the trends, strategies, and technologies that will shape the search marketing landscape.
If you’re looking to assess your paid search strategy and design an industry-aligned plan for 2024, then this webinar is for you.
5 Public speaking tips from TED - Visualized summarySpeakerHub
From their humble beginnings in 1984, TED has grown into the world’s most powerful amplifier for speakers and thought-leaders to share their ideas. They have over 2,400 filmed talks (not including the 30,000+ TEDx videos) freely available online, and have hosted over 17,500 events around the world.
With over one billion views in a year, it’s no wonder that so many speakers are looking to TED for ideas on how to share their message more effectively.
The article “5 Public-Speaking Tips TED Gives Its Speakers”, by Carmine Gallo for Forbes, gives speakers five practical ways to connect with their audience, and effectively share their ideas on stage.
Whether you are gearing up to get on a TED stage yourself, or just want to master the skills that so many of their speakers possess, these tips and quotes from Chris Anderson, the TED Talks Curator, will encourage you to make the most impactful impression on your audience.
See the full article and more summaries like this on SpeakerHub here: https://speakerhub.com/blog/5-presentation-tips-ted-gives-its-speakers
See the original article on Forbes here:
http://www.forbes.com/forbes/welcome/?toURL=http://www.forbes.com/sites/carminegallo/2016/05/06/5-public-speaking-tips-ted-gives-its-speakers/&refURL=&referrer=#5c07a8221d9b
Lesson 12 - The Blessed Hope: The Mark of the Christian.pptxCelso Napoleon
Lesson 12 - The Blessed Hope: The Mark of the Christian
SBS – Sunday Bible School
Adult Bible Lessons 2nd quarter 2024 CPAD
MAGAZINE: THE CAREER THAT IS PROPOSED TO US: The Path of Salvation, Holiness and Perseverance to Reach Heaven
Commentator: Pastor Osiel Gomes
Presentation: Missionary Celso Napoleon
Renewed in Grace
Unleash your spiritual growth journey as a truth-seeker!
Learn More:
👉https://tkg.tf/4D
Tracking "The Blessing" - Christianity · Spiritual Growth · Success
Do you ever feel like your Bible highlighting isn't quite enough to ignite lasting spiritual growth? Have you struggled to retain key takeaways from your Bible study sessions?
Discover how living in 4D can transform your highlighting into a strategic tool for spiritual development.
Learn More:
👉https://tkg.tf/4D
In this video, you'll gain insights on:
How highlighting key verses and themes can enhance memory and retention of Scripture (we see a few key ones, here!)
Studies have shown that highlighting can significantly improve information recall. Highlighting key points visually reinforces them in your mind, leading to better long-term memory.
How to personalize your Bible study through strategic highlighting. Don't just highlight everything!
This video will teach you how to strategically highlight based on what resonates with you, focusing on central themes, recurring ideas, or connections between different passages.
Watch More:
👉https://tkg.tf/4D
How connecting highlighted passages can reveal deeper biblical truths. By highlighting these connections, you can see the bigger picture and uncover the underlying messages within Scripture.
By the end of this video, you'll be equipped to unlock the hidden potential within your highlighted Bible and embark on a transformative spiritual growth journey! Don't forget to like and subscribe for more inspiring content on deepening your faith.
Note: For Christians seeking to enrich their Bible study and deepen their faith, as well as any other spiritual seeker of truth and growth.
Learn More:
👉https://tkg.tf/4D
New York City love spells in Dallas, TX.spellshealer8
Get ex back TX (+256) 789- 682- 081 Love spells in Houston, TX Astrologer Psychic near me to remove negative energy. Protection spells by Spell Caster | Love Spells | Black Magic | the witchcraft. Black magic expert and voodoo love spells that work overnight to retrieve that love | Best Psychic in Houston with powerful voodoo to renew your relationship & make your relationship stronger. love spells to bring back the feelings of love for ex-lovers.
https://spellshealer8.wixsite.com/binding-powerful-los
Increase the intimacy, affection & love between you and your lover using voodoo relationship love spells in USA. money spells, easy love spells with just words, think of me spell, powerful love spell, spells of love, spells that work, love potion to attract a man, easy love spells with just words, pink candle prayer, white magic spells, call me spell, manifestation spell, gay love spells, Commitment spells, business spells and, how to bring back lost love in a relationship, Witchcraft love spells that work immediately to increase love & intimacy in your relationship. Attraction love spells to attract someone, stop a divorce, prevent a breakup & get your ex back.
REUNITE WITH AN EX LOVER IN 72 HOURS
If your lover is gone, don't be desperate anymore! You are a few clicks away from a prompt resolution of your problem: We will our spiritual powers to bring him/her back. This service has been the reason of so many happy endings that you should consider it as a serious solution. Let us show you our method with zero chances of rejection. Don't waste your precious time; get your lover back NOW!
MAKE HIM/HER LOVE ME
You love someone but this isn't mutual? Don't wait for the deluge and make him or her love you now. This service will create a great alchemy between this person and you. In just a few weeks, you can make the person you dream of falling in love with you. We recommend you to combine this service with a Marriage ritual if you want this person to commit you.
BREAK UP A RELATIONSHIP
The perfect service to break up a relationship you don't think legitimate. Your lover has gone with someone else? You love someone but this person is already involved in a relationship? Don't hesitate to break them up as this ritual and prayer is very powerful and will give very good results in a few weeks only.
STOP A DIVORCE NOW
Your husband or you wife is thinking about divorce but you don't want this to happen? Order this service now to reinforce the bonds of your relationship and save your marriage. This service will make him/her realize that a divorce would be a mistake and will strengthen love and passion. With permanent results, this service will guarantee a long lasting marriage and will make you happy.
FAITHFULNESS
Your partner cheats on you? This love ritual is definitely the one you need! Your lover will dream about you every night and will realize the pain you have been suffering since he/she
LOVE CHARMS
I DO ALL THE FOLLOWING SPELLS
*Binding Your
Astronism, Cosmism and Cosmodeism: the space religions espousing the doctrine...Cometan
This lecture created by Brandon Taylorian (aka Cometan) specially for the CESNUR Conference held Bordeaux in June 2024 provides a brief introduction to the legacy of religious and philosophical thought that Astronism emerges from, namely the discourse on transcension started assuredly by the Cosmists in Russia in the mid-to-late nineteenth century and then carried on and developed by Mordecai Nessyahu in Cosmodeism in the twentieth century. Cometan also then provides some detail on his story in founding Astronism in the early twenty-first century from 2013 along with details on the central Astronist doctrine of transcension. Finally, the lecture concludes with some contributions made by space religions and space philosophy and their influences on various cultural facets in art, literature and film.
Tales of This and Another Life - Chapters.pdfMashaL38
This book is one of the best of the translated ones, for it has a warning character for all those who find themselves in the experience of material life. Irmão X provides a shrewd way of describing the subtleties and weaknesses that can jeopardize our intentions, making us more attentive and vigilant by providing us with his wise pages, reminding us between the lines of the Master's words: "Pray and watch."
Lucid Dreaming: Understanding the Risks and Benefits
The ability to control one's dreams or for the dreamer to be aware that he or she is dreaming. This process, called lucid dreaming, has some potential risks as well as many fascinating benefits. However, many people are hesitant to try it initially for fear of the potential dangers. This article aims to clarify these concerns by exploring both the risks and benefits of lucid dreaming.
The Benefits of Lucid Dreaming
Lucid dreaming allows a person to take control of their dream world, helping them overcome their fears and eliminate nightmares. This technique is particularly useful for mental health. By taking control of their dreams, individuals can face challenging scenarios in a controlled environment, which can help reduce anxiety and increase self-confidence.
Addressing Common Concerns
Physical Harm in Dreams Lucid dreaming is fundamentally safe. In a lucid dream, everything is a creation of your mind. Therefore, nothing in the dream can physically harm you. Despite the vividness and realness of the dream experience, it remains entirely within your mental landscape, posing no physical danger.
Mental Health Risks Concerns about developing PTSD or other mental illnesses from lucid dreaming are unfounded. As soon as you wake up, it's clear that the events experienced in the dream were not real. On the contrary, lucid dreaming is often seen as a therapeutic tool for conditions like PTSD, as it allows individuals to reframe and manage their thoughts.
Potential Risks of Lucid Dreaming
While generally safe, lucid dreaming does come with a few risks as well:
Mixing Dream Memories with Reality Long-term lucid dreamers might occasionally confuse dream memories with real ones, creating false memories. This issue is rare and preventable by maintaining a dream journal and avoiding lucid dreaming about real-life people or places too frequently.
Escapism Using lucid dreaming to escape reality can be problematic if it interferes with your daily life. While it is sometimes beneficial to escape and relieve the stress of reality, relying on lucid dreaming for happiness can hinder personal growth and productivity.
Feeling Tired After Lucid Dreaming Some people report feeling tired after lucid dreaming. This tiredness is not due to the dreams themselves but often results from not getting enough sleep or using techniques that disrupt sleep patterns. Taking breaks and ensuring adequate sleep can prevent this.
Mental Exhaustion Lucid dreaming can be mentally taxing if practiced excessively without breaks. It’s important to balance lucid dreaming with regular sleep to avoid mental fatigue.
Lucid dreaming is safe and beneficial if done with caution. It has many benefits, such as overcoming fear and improving mental health, and minimal risks. There are many resources and tutorials available for those interested in trying it.
The Book of Samuel is a book in the Hebrew Bible, found as two books in the Old Testament. The book is part of the Deuteronomistic history, a series of books that constitute a theological history of the Israelites and that aim to explain God's law for Israel under the guidance of the prophets.
2nd issue of Volume 15. A magazine in urdu language mainly based on spiritual treatment and learning. Many topics on ISLAM, SUFISM, SOCIAL PROBLEMS, SELF HELP, PSYCHOLOGY, HEALTH, SPIRITUAL TREATMENT, Ruqya etc.A very useful magazine for everyone.
Trusting God's Providence | Verse: Romans 8: 28-31JL de Belen
Trusting God's Providence.
Providence - God’s active preservation and care over His creation. God is both the Creator and the Sustainer of all things Heb. 1:2-3; Col. 1:17
-God keep His promises.
-God’s general providence is toward all creation
- All things were made through Him
God’s special providence is toward His children.
We may suffer now, but joy can and will come
God can see what we cannot see
Heartfulness Magazine - June 2024 (Volume 9, Issue 6)heartfulness
Dear readers,
This month we continue with more inspiring talks from the Global Spirituality Mahotsav that was held from March 14 to 17, 2024, at Kanha Shanti Vanam.
We hear from Daaji on lifestyle and yoga in honor of International Day of Yoga, June 21, 2024. We also hear from Professor Bhavani Rao, Dean at Amrita Vishwa Vidyapeetham University, on spirituality in action, the Venerable BhikkuSanghasena on how to be an ambassador for compassion, Dr. Tony Nader on the Maharishi Effect, Swami Mukundananda on the crossroads of modernization, Tejinder Kaur Basra on the purpose of work, the Venerable GesheDorjiDamdul on the psychology of peace, the Rt. Hon. Patricia Scotland, KC, Secretary-General of the Commonwealth, on how we are all related, and world-renowned violinist KumareshRajagopalan on the uplifting mysteries of music.
Dr. Prasad Veluthanar shares an Ayurvedic perspective on treating autism, Dr. IchakAdizes helps us navigate disagreements at work, Sravan Banda celebrates World Environment Day by sharing some tips on land restoration, and Sara Bubber tells our children another inspiring story and challenges them with some fun facts and riddles.
Happy reading,
The editors
Lição 12: João 15 a 17 – O Espírito Santo e a Oração Sacerdotal | 2° Trimestr...OmarBarrezueta1
Esta lição é uma oportunidade para discutirmos um assunto multo mal interpretado no contexto cristão, que é o fato de algumas pessoas pensarem que o conhecer Jesus é ter a nossa vida mudada em todas as áreas, como se Deus tivesse o dever de transportar-nos deste mundo para um outro mundo onde muitas coisas maravilhosas que desejamos seriam reais. No entanto, a nossa fé não nos tira do mundo após nos convertermos; ao invés disso, permanecemos vivendo sob as mesmas circunstâncias. O propósito de Deus não é nos tirar do mundo, mas nos livrar das ações do maligno (Jo 17.15), Sendo assim, a vida eterna não significa estar fora da realidade deste mundo, mas conhecer o único Deus verdadeiro (Jo 17.3).
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
Mental health has been in the news quite a bit lately. Dozens of U.S. states are currently suing Meta for contributing to the youth mental health crisis by inserting addictive features into their products, while the U.S. Surgeon General is touring the nation to bring awareness to the growing epidemic of loneliness and isolation. The country has endured periods of low national morale, such as in the 1970s when high inflation and the energy crisis worsened public sentiment following the Vietnam War. The current mood, however, feels different. Gallup recently reported that national mental health is at an all-time low, with few bright spots to lift spirits.
To better understand how Americans are feeling and their attitudes towards mental health in general, ThinkNow conducted a nationally representative quantitative survey of 1,500 respondents and found some interesting differences among ethnic, age and gender groups.
Technology
For example, 52% agree that technology and social media have a negative impact on mental health, but when broken out by race, 61% of Whites felt technology had a negative effect, and only 48% of Hispanics thought it did.
While technology has helped us keep in touch with friends and family in faraway places, it appears to have degraded our ability to connect in person. Staying connected online is a double-edged sword since the same news feed that brings us pictures of the grandkids and fluffy kittens also feeds us news about the wars in Israel and Ukraine, the dysfunction in Washington, the latest mass shooting and the climate crisis.
Hispanics may have a built-in defense against the isolation technology breeds, owing to their large, multigenerational households, strong social support systems, and tendency to use social media to stay connected with relatives abroad.
Age and Gender
When asked how individuals rate their mental health, men rate it higher than women by 11 percentage points, and Baby Boomers rank it highest at 83%, saying it’s good or excellent vs. 57% of Gen Z saying the same.
Gen Z spends the most amount of time on social media, so the notion that social media negatively affects mental health appears to be correlated. Unfortunately, Gen Z is also the generation that’s least comfortable discussing mental health concerns with healthcare professionals. Only 40% of them state they’re comfortable discussing their issues with a professional compared to 60% of Millennials and 65% of Boomers.
Race Affects Attitudes
As seen in previous research conducted by ThinkNow, Asian Americans lag other groups when it comes to awareness of mental health issues. Twenty-four percent of Asian Americans believe that having a mental health issue is a sign of weakness compared to the 16% average for all groups. Asians are also considerably less likely to be aware of mental health services in their communities (42% vs. 55%) and most likely to seek out information on social media (51% vs. 35%).
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
Creative operations teams expect increased AI use in 2024. Currently, over half of tasks are not AI-enabled, but this is expected to decrease in the coming year. ChatGPT is the most popular AI tool currently. Business leaders are more actively exploring AI benefits than individual contributors. Most respondents do not believe AI will impact workforce size in 2024. However, some inhibitions still exist around AI accuracy and lack of understanding. Creatives primarily want to use AI to save time on mundane tasks and boost productivity.
Organizational culture includes values, norms, systems, symbols, language, assumptions, beliefs, and habits that influence employee behaviors and how people interpret those behaviors. It is important because culture can help or hinder a company's success. Some key aspects of Netflix's culture that help it achieve results include hiring smartly so every position has stars, focusing on attitude over just aptitude, and having a strict policy against peacocks, whiners, and jerks.
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
PepsiCo provided a safe harbor statement noting that any forward-looking statements are based on currently available information and are subject to risks and uncertainties. It also provided information on non-GAAP measures and directing readers to its website for disclosure and reconciliation. The document then discussed PepsiCo's business overview, including that it is a global beverage and convenient food company with iconic brands, $91 billion in net revenue in 2023, and nearly $14 billion in core operating profit. It operates through a divisional structure with a focus on local consumers.
Content Methodology: A Best Practices Report (Webinar)contently
This document provides an overview of content methodology best practices. It defines content methodology as establishing objectives, KPIs, and a culture of continuous learning and iteration. An effective methodology focuses on connecting with audiences, creating optimal content, and optimizing processes. It also discusses why a methodology is needed due to the competitive landscape, proliferation of channels, and opportunities for improvement. Components of an effective methodology include defining objectives and KPIs, audience analysis, identifying opportunities, and evaluating resources. The document concludes with recommendations around creating a content plan, testing and optimizing content over 90 days.
How to Prepare For a Successful Job Search for 2024Albert Qian
The document provides guidance on preparing a job search for 2024. It discusses the state of the job market, focusing on growth in AI and healthcare but also continued layoffs. It recommends figuring out what you want to do by researching interests and skills, then conducting informational interviews. The job search should involve building a personal brand on LinkedIn, actively applying to jobs, tailoring resumes and interviews, maintaining job hunting as a habit, and continuing self-improvement. Once hired, the document advises setting new goals and keeping skills and networking active in case of future opportunities.
A report by thenetworkone and Kurio.
The contributing experts and agencies are (in an alphabetical order): Sylwia Rytel, Social Media Supervisor, 180heartbeats + JUNG v MATT (PL), Sharlene Jenner, Vice President - Director of Engagement Strategy, Abelson Taylor (USA), Alex Casanovas, Digital Director, Atrevia (ES), Dora Beilin, Senior Social Strategist, Barrett Hoffher (USA), Min Seo, Campaign Director, Brand New Agency (KR), Deshé M. Gully, Associate Strategist, Day One Agency (USA), Francesca Trevisan, Strategist, Different (IT), Trevor Crossman, CX and Digital Transformation Director; Olivia Hussey, Strategic Planner; Simi Srinarula, Social Media Manager, The Hallway (AUS), James Hebbert, Managing Director, Hylink (CN / UK), Mundy Álvarez, Planning Director; Pedro Rojas, Social Media Manager; Pancho González, CCO, Inbrax (CH), Oana Oprea, Head of Digital Planning, Jam Session Agency (RO), Amy Bottrill, Social Account Director, Launch (UK), Gaby Arriaga, Founder, Leonardo1452 (MX), Shantesh S Row, Creative Director, Liwa (UAE), Rajesh Mehta, Chief Strategy Officer; Dhruv Gaur, Digital Planning Lead; Leonie Mergulhao, Account Supervisor - Social Media & PR, Medulla (IN), Aurelija Plioplytė, Head of Digital & Social, Not Perfect (LI), Daiana Khaidargaliyeva, Account Manager, Osaka Labs (UK / USA), Stefanie Söhnchen, Vice President Digital, PIABO Communications (DE), Elisabeth Winiartati, Managing Consultant, Head of Global Integrated Communications; Lydia Aprina, Account Manager, Integrated Marketing and Communications; Nita Prabowo, Account Manager, Integrated Marketing and Communications; Okhi, Web Developer, PNTR Group (ID), Kei Obusan, Insights Director; Daffi Ranandi, Insights Manager, Radarr (SG), Gautam Reghunath, Co-founder & CEO, Talented (IN), Donagh Humphreys, Head of Social and Digital Innovation, THINKHOUSE (IRE), Sarah Yim, Strategy Director, Zulu Alpha Kilo (CA).
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
The search marketing landscape is evolving rapidly with new technologies, and professionals, like you, rely on innovative paid search strategies to meet changing demands.
It’s important that you’re ready to implement new strategies in 2024.
Check this out and learn the top trends in paid search advertising that are expected to gain traction, so you can drive higher ROI more efficiently in 2024.
You’ll learn:
- The latest trends in AI and automation, and what this means for an evolving paid search ecosystem.
- New developments in privacy and data regulation.
- Emerging ad formats that are expected to make an impact next year.
Watch Sreekant Lanka from iQuanti and Irina Klein from OneMain Financial as they dive into the future of paid search and explore the trends, strategies, and technologies that will shape the search marketing landscape.
If you’re looking to assess your paid search strategy and design an industry-aligned plan for 2024, then this webinar is for you.
5 Public speaking tips from TED - Visualized summarySpeakerHub
From their humble beginnings in 1984, TED has grown into the world’s most powerful amplifier for speakers and thought-leaders to share their ideas. They have over 2,400 filmed talks (not including the 30,000+ TEDx videos) freely available online, and have hosted over 17,500 events around the world.
With over one billion views in a year, it’s no wonder that so many speakers are looking to TED for ideas on how to share their message more effectively.
The article “5 Public-Speaking Tips TED Gives Its Speakers”, by Carmine Gallo for Forbes, gives speakers five practical ways to connect with their audience, and effectively share their ideas on stage.
Whether you are gearing up to get on a TED stage yourself, or just want to master the skills that so many of their speakers possess, these tips and quotes from Chris Anderson, the TED Talks Curator, will encourage you to make the most impactful impression on your audience.
See the full article and more summaries like this on SpeakerHub here: https://speakerhub.com/blog/5-presentation-tips-ted-gives-its-speakers
See the original article on Forbes here:
http://www.forbes.com/forbes/welcome/?toURL=http://www.forbes.com/sites/carminegallo/2016/05/06/5-public-speaking-tips-ted-gives-its-speakers/&refURL=&referrer=#5c07a8221d9b
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
Everyone is in agreement that ChatGPT (and other generative AI tools) will shape the future of work. Yet there is little consensus on exactly how, when, and to what extent this technology will change our world.
Businesses that extract maximum value from ChatGPT will use it as a collaborative tool for everything from brainstorming to technical maintenance.
For individuals, now is the time to pinpoint the skills the future professional will need to thrive in the AI age.
Check out this presentation to understand what ChatGPT is, how it will shape the future of work, and how you can prepare to take advantage.
The document provides career advice for getting into the tech field, including:
- Doing projects and internships in college to build a portfolio.
- Learning about different roles and technologies through industry research.
- Contributing to open source projects to build experience and network.
- Developing a personal brand through a website and social media presence.
- Networking through events, communities, and finding a mentor.
- Practicing interviews through mock interviews and whiteboarding coding questions.
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
1. Core updates from Google periodically change how its algorithms assess and rank websites and pages. This can impact rankings through shifts in user intent, site quality issues being caught up to, world events influencing queries, and overhauls to search like the E-A-T framework.
2. There are many possible user intents beyond just transactional, navigational and informational. Identifying intent shifts is important during core updates. Sites may need to optimize for new intents through different content types and sections.
3. Responding effectively to core updates requires analyzing "before and after" data to understand changes, identifying new intents or page types, and ensuring content matches appropriate intents across video, images, knowledge graphs and more.
A brief introduction to DataScience with explaining of the concepts, algorithms, machine learning, supervised and unsupervised learning, clustering, statistics, data preprocessing, real-world applications etc.
It's part of a Data Science Corner Campaign where I will be discussing the fundamentals of DataScience, AIML, Statistics etc.
Time Management & Productivity - Best PracticesVit Horky
Here's my presentation on by proven best practices how to manage your work time effectively and how to improve your productivity. It includes practical tips and how to use tools such as Slack, Google Apps, Hubspot, Google Calendar, Gmail and others.
The six step guide to practical project managementMindGenius
The six step guide to practical project management
If you think managing projects is too difficult, think again.
We’ve stripped back project management processes to the
basics – to make it quicker and easier, without sacrificing
the vital ingredients for success.
“If you’re looking for some real-world guidance, then The Six Step Guide to Practical Project Management will help.”
Dr Andrew Makar, Tactical Project Management
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
During this webinar, Anand Bagmar demonstrates how AI tools such as ChatGPT can be applied to various stages of the software development life cycle (SDLC) using an eCommerce application case study. Find the on-demand recording and more info at https://applitools.info/b59
Key takeaways:
• Learn how to use ChatGPT to add AI power to your testing and test automation
• Understand the limitations of the technology and where human expertise is crucial
• Gain insight into different AI-based tools
• Adopt AI-based tools to stay relevant and optimize work for developers and testers
* ChatGPT and OpenAI belong to OpenAI, L.L.C.
The document discusses various AI tools from OpenAI like GPT-3 and DALL-E 2, as well as ChatGPT. It explores how search engines are using AI and things to consider around AI-generated content. Potential SEO uses of ChatGPT are also presented, such as generating content at scale, conducting topic research, and automating basic coding tasks. The document encourages further reading on using ChatGPT for SEO purposes.
2. Problem
• Parsing of context-free languages
– active research topic from 60’s to 80’s
– rich variety of parsing techniques are known
• general CFL parsing:
– Earley’s algorithm, Cocke-Younger-Kasami (CYK)
• deterministic parsing:
– SLL(k), LL(k), SLR(k), LR(k), LALR(k), LA(l)LR(k)..
• Problem: most of these techniques were invented by
automata theory people
– terminology is fairly obscure: leftmost derivations, rightmost
derivations, handles, viable prefixes, ….
– string rewriting is very clean but not intuitive for most PL people
– descriptions in compiler textbooks are obscure/erroneous
– connections between different parsing techniques are lost
• Question: is there an easier way of thinking about parsing
than in terms of strings and string rewriting?
11/23/2011 2
3. New abstraction
• For any context-free grammar, construct a Grammar Flow
Graph (GFG)
– syntax: representation of grammar as a control-flow graph
– semantics: executable representation
• special kind of non-deterministic pushdown automaton
• Parsing problems
– become path problems in GFG
• Alphabet soup of grammar classes like LL(k), SLL(k), LR(k),
LALR(k), SLR(k) etc. can be viewed as choices along three
dimensions
– non-determinism: how many paths can we explore at a time?
• all (Earley), only one (LL), some (LR)
– look-ahead: how much do we know about future?
• solve fixpoint equations over sets
– context: how much do we remember about the past?
• procedure cloning
11/23/2011 3
4. GFG example
SAa | bAc | Bc | bBa
Ad START-S
Bd ²
² ²
²
S.bAc ² ² S.bBa
² ²
b b
S.Aa S.Bc
START-A Sb.Ac START-B
Sb.Ba
² ²
SA.a ² A.d B.d
SB.c
d SbA.c d SbB.a
a c
c a
SAa. Ad. Bd.
SBc.
² SbAc. ² SbBa.
END-A END-B
² ²
² ²
²
²
END-S
5. GFG construction
For each non-terminal A, create nodes labeled START-A and END-A.
For each production in grammar, create a “procedure” and connect to
START and END nodes of LHS non-terminal as shown below.
A ² START-A
² A.
² END-A
A bXY ² b ²
START-A A.bXY A b.XY AbX.Y AbXY. END-A
² ² ² ²
START-X ……. END-X START-Y …….
END-Y
Edges labeled ²: only at entry/exit of START-A and END-A nodes.
Fan-out: only at exit of START-A nodes and END-A nodes
11/23/2011 transition node: node whose outgoing edge is labeled with a terminal
Terminal 5
7. Non-deterministic GFG automaton
• Interpretation of GFG: NGA
– similar to NFA START-S
• Rules:
– begin at START-S
– at START nodes, make non-
deterministic choice b b
– at END nodes, must follow
CFL path
• “return to the same procedure d
from which you made the call” d
• CFL path from START to a c
c a
END leftmost derivation
• Label(path):
– sequence of terminal
symbols labeling edges in
path
END-S
– Label of CFL path from
START to END is a word in SAa | bAc | Bc | bBa
language generated by CFG
Ad
Bd
11/23/2011 7
8. Parsing problem
• Paths(l):
– set of paths with label l
START-S
– inverse relation of Label
• Parsing problem: given a
grammar G and a string S,
– find all paths in GFG(G) that
generate S, or b b
– demonstrate that there is no
such path
• Parallel paths: d
d
– P1 = START-S + A a c
c a
– P2 = START-S + B
– Label(P1) = Label(P2)
– Equivalence relation on
paths originating at START-
S END-S
• Ambiguous grammar
– two or more parallel paths SAa | bAc | Bc | bBa
START-S+ END-S Ad
Bd
11/23/2011 8
10. Addition to GFG
• We need to be able START
to talk about SbAc
sentential forms, not SbBa
just sentences SAa SBc
• Small modification to b b
GFG: A Ad
A
B Bd
– add transitions labeled B
with non-terminals at a d
procedure calls c d
c a
• Some paths will have
edges labeled with
non-terminals
– non-terminals that END
have not been
“expanded out” SAa | bAc | Bc | bBa
Ad
Bd
11/23/2011 10
11. Compressed GFG paths
START
• More compact representation of
GFG path
• Idea: START-P
– collapse portion of path between P
start and end of a given procedure END-P
and replace with non-terminal
• Point: completed calls cannot P1
affect further evolution of path
so we need not store full path
• Edges going out of END nodes
of procedures will never appear
in compressed representation
11/23/2011 11
12. NFA for compressed paths
• Start from extended START
GFG SbAc SbBa
• Remove edges out
SAa SBc
b b
of END nodes since A Ad B Bd
these will never be A B
in compressed path a d c d
c a
• Each path in NFA
corresponds to a
compressed GFG
END
path
SAa | bAc | Bc | bBa
Ad
Bd
11/23/2011 12
14. Recall: NFA simulation
• Input string is processed left to
right, one symbol at a time
• Deterministic simulator keeps
track of all states NFA could be
in as the input is processed
• Simulation
– simulated state = subset of NFA
states
– if current simulated state is C
and next input symbol is t ,
compute next simulated N as {s0,s1,s4} !a {s2} !a {s2,s3,s7} ….
follows:
• scanning: if state si 2 C and NFA
has transition si t sj, add sj to
N
• prediction: if state sj 2 N and NFA
has transition sj sk, add sk to
N
– initial simulated state = set of
initial states of NFA closed with
prediction rule
11/23/2011 14
15. Analog in GFG
• First cut: use exactly the SAa | bAc | Bc | bBa
same idea Ad
Bd
– current state C, next state N,
next input symbol is t S0
– scanning: if state si 2 C and
NFA has transition
si t sj, add sj to N S4 S13
– prediction: if state sj 2 N and S1 b S8 b
NFA has transition S5 S14
sj sk, add sk to N
S2 S17 S9 S11
• Problem: not clear how to a d
S6 S15
make ²-transitions at return c c d
S3 S18 S10 S12 a
S7
states like s18 and s12 S16
• Solution: keep “return
addresses” as in Earley
S19
{S0,S1,S4,S8,S13,S17,S11} !d {S12,S18, ?????}
11/23/2011 15
17. Earley parser and GFG states
• A given § set can contain multiple instances of the
same GFG state.
• Example: SaS|a
• Earley set §i
– <Sa.S, i-1>
– <Sa., i-1>
– <S.aS, i>
– <S.a, i>
– <SaS. , i-2>
– <SaS., i-3>
– ……
– <SaS., 0>
11/23/2011 17
18. Earley’s parser and
ambiguous grammars
• If an Earley configuration §t
can be added to a given § <X ® . , p1>
set by two or more <Y ¯. , p2>
configurations, grammar is
ambiguous <Z ° A. ±, p>
• Example: substring between
positions p and t can be
derived from A in two
different ways
11/23/2011 18
20. Look-ahead computation
• Look-ahead at point p in GFG:
– first k symbols you might encounter on path starting at p
– k is a small integer that is given for entire grammar
• Subtle point:
– look-ahead may depend on path from START that you took to get to p
– (eg) 2-look-ahead at entry of N is different for red and blue calls
• Two approaches:
– context-independent look-ahead: first k symbols on paths starting at p
– context-dependent look-ahead: given a path C from START to p, what
are the first k symbols on any path starting at p that extends C
S N
{xa} {ya,yb}
{aa,ab} {ab,bc}
x y
S xNab | yNbc N a
N
N a |
a b
11/23/2011 b c 20
21. FIRSTk sets
• FIRSTk(A): set of strings of length k or less
– If A * s where s is a terminal string of length k or less, s ²
FIRSTk(A)
– If A * s where s is a string longer than k symbols, then k-prefix of
s ² FIRSTk(A)
• Intuition:
– non-terminal A represents a set, which is the set of strings we can
derive from it
– FIRSTk(A) is the set of k-prefixes of these strings
• Easy to extend FIRSTk to sequences of grammar symbols
S N
S xNab | yNbc
N a |
FIRST2(N)= {a, }
x y
FIRST2(Nab) a
= {aa,ab} N N
a b
b c 21
11/23/2011
22. Useful string functions
• Concatenation: s + t
– (eg) xy + abc = xyabc
• k-prefix of string s: sk
– (eg) (xyz)2 = xy, (x)2 = x, ( )2 =
• Composition of concatenation and k-prefix: s +k t
– defined as (s+t)k
– (eg) x +2 yz = xy
– operation is associative
• Easy result: (s+t)k = (sk+tk)k = sk +k tk
• Operations can be extended to sets in the obvious
way
– (eg) {a,bcd} +2 { ,x,yz} = {a,ax,ay,bc}
11/23/2011 22
23. FIRSTk
FIRSTk(²) = {²}
FIRSTk(t) = {t}
FIRSTk(A) = FIRSTk(X1X2…Xn) U
FIRSTk(Y1Y2…Ym) U …
//rhs of productions
FIRSTk(X1X2..Xn) = FIRSTk(X1) +k FIRSTk(X2)
+k…+k FIRSTk(Xn)
11/23/2011 23
24. FIRSTk example
S aAab | bAb
A cAB | | a
B
FIRST2(S) = FIRST2(aAab) U FIRST2(bAb)
= ({a}+2 FIRST2(A) +2 {ab}) U ({b}+2 FIRST2(A) +2 {b})
FIRST2(A) = FIRST2(cAB) U {²} U{a} = ({c} +2 FIRST2(A) +2 FIRST2(B)) U {²} U {a}
FIRST2(B) = { }
FIRST2(A) ={²,a,c,ca,cc}
FIRST2(B) = {²}
FIRST2(S)={aa,ac,bb,ba,bc}
11/23/2011 24
25. Context-independent look-aheads
S A B
a b c
A A a
A
a b ?
b B
{ab}
{b$}
Se={$$} Be
Ae
Compute FOLLOWk(A) sets: strings of length k that can be encountered
after you return from non-terminal A
Se = {$$}
Ae = (FIRST2({ab}) +2 Se) U (FIRST2({b})+2 Se) U (FIRST2(B) +2 Ae)
Be = Ae
Solution: Se = {$$} Ae = {ab,b$} Be = {ab,b$}
From these FOLLOW sets, we can now compute look-ahead at any GFG point.
26. Computing context-independent
look-ahead sets
• Algorithm:
– For each non-terminal A, compute FIRSTk(A)
• First k terminals you encounter on path A-START + A-END
– For each non-terminal A, compute FOLLOWk(A)
• First k terminals you encounter on path that extends a GFG
path START + A-END
– Use the FIRSTk and FOLLOWk sets to compute the
look-ahead at any point of interest in GFG
• You can even compute FIRSTk and FOLLOWk
sets in one big iteration if you want.
• This computation is independent of the particular
parsing method used
11/23/2011 26
28. Context-dependent look-ahead
• In running example,
– look-aheads for N for red S
call to N are disjoint N
– look-aheads for N for blue {xa} {ya,yb} {aa,ab} {ab,bc}
call to N are disjoint
– context-independent look- x y
ahead computation a
combines the look-aheads N N
from all the call sites of N b
at the bottom of N and a
{bc}
propagates them to the top b c
• Idea:
– compute look-aheads {ab}
separately for each context
– keep track of context while
parsing S xNab | yNbc
we can get a more capable N a |
parser
Input string: xab$$
11/23/2011 28
29. Tracking context by cloning
• Grammar:
S xNab | yNbc S xN1ab | yN2bc
N a | N1 a | N2 a |
S [N,{ab}]
N1 [N,{bc}]
N2
{aa} {ab} {ab} {bc}
x y
a a
[N,{ab}]
N1 [N,{bc}]
N2
a b
b c
11/23/2011 29
30. General idea of cloning
• Cloning creates copies of productions
• Intuitively we would like to create a clone of a production for each of
its contexts and write-down look-ahead
– but set of contexts for a production is usually infinite
• Solution:
– create finite number of equivalence classes of contexts for a given
production
– create a clone for each equivalence class
– compute context-independent look-ahead
• Two cloning rules are important in practice
– k-look-ahead cloning: two contexts are in same equivalence class if
their k-look-aheads are identical (used in LL(k))
– reachability cloning: two contexts C1 and C2 are in same equivalence
class if the set of GFG nodes reachable by paths with label(C1) is equal
to set of GFG nodes reachable by paths with label(C2) (used in LR(0))
– LR(k) uses a combination of them
11/23/2011 30
31. k-look-ahead cloning (intuitive idea)
S A B S
a b c a b
A A A a d
[A,{ab} [A,{b$}]
a b
a b
b B
{b$} b
{ab}
[A,{ab}] [A,{b$}]
c c
[A,{da}] a [A,{db}] a
[B,{ab}] [B,{b$}]
{b$}
{ab}
Other clones not shown
k
If there are |T| terminal symbols, you may end up with 2|T| clones of a given production
32. k-look-ahead cloning
• G=(V,T,P,S):grammar, k:positive integer.
• Tk(G) is following grammar
– nonterminals: {[A,R]| A in V -T, and R µ Tk}
– terminals: T
– start symbol: [S,{$k}]
– rules: all rules of the form [A,R] X1'X2'X3'...Xm' where for
some rule A X1X2X3...Xm in P
• Xi' = Xi if Xi is a terminal
• Xi' = [Xi, FIRSTk(Xi+1,..Xm) +k R] when Xi is a non-terminal.
• Intuition:
– after this kind of cloning, k-look-aheads at the end of a procedure
are identical for all return edges
– so doing a context-independent look-ahead computation on the
transformed grammar does not tell you anything you did not
already know about k-look-aheads
11/23/2011 32
34. Intuition
• This class of grammars has the following
property:
– if s is a string in the language, then for any prefix
p of s, there is a unique path P from START such
that label(P) = p (modulo look-ahead)
• So we need to follow only one path through
GFG for a given input string, using look-
ahead to eliminate alternatives
• Roughly analogous to DFAs in the CFL world
11/23/2011 34
35. LL(k) parsing
• Only one path can be
followed by the parser
– so at procedure call for S
non-terminal N, we must N
know exactly which {xa} {ya,yb} {aa,ab} {ab,bc}
procedure (rule) to call
• Simple LL(k) parsing: x y
a
– make decision based on N N
context-independent look- a b
ahead of k symbols at entry
point for N b c
• LL(k) parsing:
– use context-dependent
look-ahead of k symbols
– procedure cloning S xNab | yNbc
technique converts LL(k) N a |
grammar into SLL(k)
grammar
Grammar is LL(2) but not SLL(2)
11/23/2011 35
36. Parser
• Modify Earley parser to
– track compressed paths instead of full paths
• transitions labeled by non-terminals and terminals
– eliminate return addresses
• at the end of a production
– A X1X2..Xn: pop n states off and make an A transition
from the exposed state
– A ² : make an A transition from current state
– use look-ahead to eliminate alternatives
11/23/2011 36
37. START-E
E.(+ E E) E.(- E E) E.int
START-E
(
( (
E(. - E E)
- E E
E(- . E E) + int ---
START-E
E .(+ E E) E .(- E E) E .int
E E
(
) )
E (.+ E E) E
+
E (+ . E E) E int | (+ E E) | (- E E)
START-E
E.(+ E E) E .(- E E) E .int Input string: ( - ( + 8 9 ) 7 )
8 E
E int. E (+ E . E) E (- E .E)
END-E START-E START-E
E.(+ E E) E (- E E) E .int E. (+ E E) E .(- E E) E .int
9 E 7 E
E int. E (+ E E.)
END-E E int. E (- E E .)
) END-E
)
E(+ E E). E (- E E ).
END-E END-E 37
38. Many grammars are not LL(k)
• Grammar
– Eint | (E+E) | (E-E)
E
• Not clear which rule to ( (
apply until you see “+”
E E
or “-”
+ int ---
– this needs unbounded
E E
look-ahead, so grammar
is not LL(k) for any k ) )
• One solution:
– follow multiple paths till
only one survives
11/23/2011 38
40. LR grammars (informal)
• LR parsers permit limited non- START
determinism
– can follow more than one path but not
all paths like Early
• LR(0) condition: for any prefix of b b
input, the corresponding fully A B
extended compressed paths must A
have the same label
• Condition not true in general a d c d
c a
grammars: see example
– Consider string “da”
– For prefix “d”, there are two paths:
• red path
• blue path
END
– Labels of compressed paths:
• red path: “A” SAa | bAc | Bc | bBa
• blue path: “B”
Ad
• We can use modified Earley parser Bd
for these grammars
11/23/2011 40
42. Parser for LR languages
• Use the modified Earley parser we used for LL grammars
– each -state will have multiple items as in the original Earley parser
since LR parsers follow multiple paths too
• -states must follow a stack discipline for modified Earley parser to
work
• Since we are following multiple paths, this might break down
– shift-reduce conflict: parallel compressed paths
• P1 to a scan node and P2 to an EXIT node (push/pop conflict)
– reduce-reduce conflict: parallel compressed paths
• P1 and P2 to different EXIT nodes (pop/pop conflict)
• If grammar does not have shift-reduce or reduce-reduce conflicts,
we can use modified Earley parser and follow compressed paths
while maintaining a stack discipline for -states
• How do we determine whether grammar has shift-reduce or reduce-
reduce conflicts?
11/23/2011 42
43. Finding LR(0) conflicts
• Compute the DFA corresponding to the
compressed path NFA
• If conflicting states are in same DFA state,
grammar has an LR(0) conflict
d Reduce-reduce conflict
S.Aa Ad.
S.bAc Bd.
S.Bc d c
A SbA.c SbAc.
S.bBa
b Sb.Ac
A.d
Sb.Ba
B.d
A.d B SbB.a SbBa.
A a
B.d
B a
SAa | bAc | Bc | bBa SA.a SAa.
Ad
11/23/2011
Bd c 43
SB.c SBc.
44. LR(0) automaton for expression grammar
) E(E+E).
E(E+E.)
E(E+.E)
int Eint. E
E.(E+E)
E.(E+E) ( E.(E-E)
E.(E – E) int + E.int
int
E .int
( E(.E+E)
E.(E+E) E E(E.+E)
Eint.
E.(E-E) E(E.- E)
E.int
E(.E-E) - E(E-.E) int
E.(E+E)
( E.(E-E)
E.int
( E E(E-E.)
)
E(E-E).
11/23/2011 44
45. Parser for LR(0) languages
• Use the modified Earley parser we used for
LL grammars
– each -state will have multiple items as in the
original Earley parser since LR parsers follow
multiple paths too
• No need to keep track of GFG nodes within
each -state
– states in compressed path DFA correspond to
possible -states
– So modified Earley parser just pushes and pops
DFA states
11/23/2011 45
46. GFG path interpretation
• Let P1 and P2 be two GFG
START
paths with identical labels
• Sufficient condition for labels START-P
START-P
of compressed paths to be
END-P
equal: END-P
– sequence of completed calls in
P1 P2
P1 and P2 are identical
• Most of the action in LR
parsers happens at EXIT
nodes of productions
11/23/2011 46
47. LR(0) conflicts: GFG
START START
t* t*
t* t*
B
Bexit u
Aexit Aexit
reduce-reduce conflict shift-reduce conflict
• LR(0) conflicts (GFG definition):
– Shift-reduce conflict: there are parallel paths P1: START + Aexit and
P2: START + scan-node
– Reduce-reduce conflict: there are parallel paths P1: START + Aexit
and P2: START + Bexit
• Claim: Let G be an LR(0) grammar according to GFG definition.
– P1 and P2 are two GFG paths that end at SCAN or END nodes, and
C(P1) and C(P2) are their compressed equivalents
– P1
11/23/2011 and P2 have the same label iff C(P1) and C(P2) have the same label
47
48. LR(0) conflicts: GFG
START START
t* t*
t* t*
B
Bexit u
Aexit Aexit
reduce-reduce conflict shift-reduce conflict
• Claim: Let G be an LR(0) grammar according to GFG definition.
– P1 and P2 are two GFG paths that end at SCAN or END nodes, and C(P1) and C(P2)
are their compressed equivalents
– P1 and P2 have the same label iff C(P1) and C(P2) have the same label
• This claim is not true if the paths do not end at SCAN or END nodes
– counterexample: in this LR(0) grammar, consider paths from START to nodes
S A.a and S .Uc
S Aa | Uc
U Ab
11/23/2011 A. 48
49. Example
START
SbAc SbBa
SAa SBc
b b
Ad Bd
• States with LR(0) conflicts
– (Ad. , Bd.)
a d c d
• Conflicting context pairs c a
(i) path label: d
– C1: START, S.Aa, A.d, Ad.
– C2: START, S.Bc, B.d, Bd.
END
(ii) path label: bd
– C3: START, S.bAc, Sb.Ac, A.d, Ad. SAa | bAc | Bc | bBa
– C4: START, S.bBa, Sb.Ba, B.d, Bd. Ad
Bd
• So grammar is not LR(0)
11/23/2011 49
50. LR(0) H&U
• A grammar G is LR(0) if
– its start symbol does not appear on the right side of any
production, and
– for every viable prefix °, whenever A ! ®. is a complete valid
item for °, then no other complete item nor any item with a
terminal to the right of the dot is valid for °.
• Comment:
– by this definition, the only other valid items that can occur
together with A ! ®. are incomplete items with a non-terminal to
the right of the dot of the form B! ¯.C±
– if First(C) contains a terminal t, it can be shown that an item of
the form Y ! .t ¸ is valid for °, violating the LR(0) condition.
Therefore, First(C) = {²}. It can be shown that this means ® = ²
– Example: this grammar is LR(0) (A . and B .Cd are valid
items for viable prefix ² )
• SB
• BCd
• CA
• A ²
11/23/2011 50
51. Look-ahead in LR grammars
START START
t* t*
t* t*
Bexit B
Aexit Aexit
reduce-reduce conflict shift-reduce conflict
• LR(k)
– for each pair of parallel paths to LR(0) conflicting states, k-look-ahead
sets are disjoint
• SLR(k):
– if there is LR(0) conflict at nodes A and B, context-insensitive look-
ahead sets of A and B are disjoint
• LALR(k): grammar is SLR(k) after reachability cloning
11/23/2011 51
52. Example
START
SbAc SbBa
SAa SBc
b b
• States with LR(0) conflicts Ad Bd
– (Ad. , Bd.)
• Conflicting context pairs a d c d
c a
(i) path label: d
– C1: START, S.Aa, A.d, Ad.
– C2: START, S.Bc, B.d, Bd.
(ii) path label: bd END
– C3: START, S.bAc, Sb.Ac, A.d, Ad.
SAa | bAc | Bc | bBa
– C4: START, S.bBa, Sb.Ba, B.d, Bd.
Ad
• Grammar is LR(1) Bd
– Look-ahead for C1: {a}, look-ahead for C2: {c}
– Look-ahead for C3: {c}, look-ahead for C4: {a}
11/23/2011 52
53. LR(1) automaton
SAa | bAc | Bc | bBa
Ad
Bd
S.Aa,$ d Ad., a
S.bAc,$ Bd., c
S.Bc,$ Ad.,c
S.bBa,$ Bd.,a
Sb.Ac,$ d
A.d, a b
Sb.Ba,$ c
B.d, c A SbA.c,$ SbAc.,$
A.d, c
A B.d, a a
B SbB.a, $ SbBa.,$
B a
SA.a,$ SAa.,$
c
11/23/2011 SB.c,$ SBc.,$ 53
54. LALR look-ahead computation
• Key observation:
– each path START s in deterministic LR(0) automaton
represents a set of contexts in the non-deterministic LR(0)
automaton
• each context in this set ends at one of the items in s
– in general, there will be multiple paths to state s in
deterministic LR(0) automaton
– so each state in LR(0) automaton represents a set of sets
of contexts
– in LALR, we merge the look-aheads for those contexts
• LALR = reachability cloning + SLR (Bermudez and
Logothetis) + unions at some nodes (see RL.) state
in diagram on next page
11/23/2011 54
55. LALR(1) but not SLR(1)
S’ S$
shift-reduce conflict S L=R|R
L *R | id
S
R L
$
S’ .S$ S’ S.$ S’ S$.
S .L=R
R S L=R.
S .R S L=.R
L S L.=R =
L .*R R .L
R L.
L .id L .*R L
R R L.
R .L L .id
S R. id
* L id.
id id
L *.R L *R.
* R
FOLLOW(S) = { $ } R .L
FOLLOW(R) = { =, $ } L .*R
* L .id L
FOLLOW(L) = { =, $ }
11/23/2011 55
56. LALR SLR grammar
S’ S$ S’ S$
S L=R|R S L1 = R2 | R1
L *R | id L1,L2,L3 *R3 | id
R L R1 L1
R2 L2
S’ .S$
S
S’ S.$
$
S’ S$. R3 L3
S .L=R
R2 S L=R.
S .R S L=.R
L1 S L.=R =
L .*R R .L
R L.
L .id L .*R L2
R1 R L.
R .L L .id
S R. id
* L id.
id id
L *.R L *R.
* R3
R .L
* L .*R
11/23/2011 56
L .id L3
57. LR(0): Reachability cloning
• Motivation: NFADFA
conversion for LR grammars START
• Driven by compressed paths
C1
• Need to verify that this cloning
satisfies sanity condition even C2 1
if grammar is not LR(0) 1 C3
2 2
• Compressed contexts C1 and
3
C2 of node A are in same
B
equivalence class if A
set of GFG nodes reachable by
paths with label(C1)
C1 and C2 will be in the same
= equivalence class. C3 is in a different class.
set of GFG nodes reachable by
paths with label(C2)
11/23/2011 57
58. Algorithm (need to write)
• G=(V,T,P,S):grammar
• R(G) is following grammar
– nonterminals: {[Ai]| A in V -T, 1 <= i <= n and
there are n edges labeled A in compressed path
DFA}
– terminals: T
– start symbol: [S]
– rules: all rules of the form [Ai] X1'X2'X3'...Xm'
where for some rule A X1X2X3...Xm in P
• Xi' = Xi if Xi is a terminal
• [Xi] when Xi is a non-terminal.
11/23/2011 58
59. Cloning for LALR(1)
• Same condition as LR(0): reachability
cloning
• Extension to LA(k)LR(l):
– cloning is governed by LR(l)
– compute SLR(k) look-aheads
– LALR(k) is LA(k)LR(0)
– LR(k) is LA(k)LR(k clone as in LR(l)
11/23/2011 59
60. Summary
• New abstraction for CFL parsing
– Grammar Flow Graph (GFG)
• Parsing problems become path problems in GFG
• Earley parser emerges as simple extension of NFA simulation
• Mechanisms
– control number of paths followed during parsing
– look-ahead:
• algorithm: solving set constraints
– context-dependent look-ahead
• algorithm: cloning
• SLL(k), LL(k), SLR(k), LR(k), LALR(k) grammars arise from
different choices of these mechanisms
• LL and LR parsers emerge as specializations of Earley parser
11/23/2011 60
62. LALR(1) example from G&J
S’ -> S #
S’S.#
S -> A B c
S A -> a
S’ .S# c B -> b
S.ABc SA.Bc SAB.c SAbc. B -> e
A.a B. B
A
B.b
a
b
Aa.
Bb.
11/23/2011 62
63. S L=R|R
L *R | id
S L = R Send
C
R L
id
*
L T R Lend
R L Rend
Shift-reduce conflict occurs at states C and Rend
(conflicting paths are S->L->Lend->C and S->R->L->Lend->Rend)
1-look-ahead at C is =
Context-independent 1-look-ahead at Rend is {=,$} so grammar is not SLR(1).
LALR(1) figures out that for conflicting state, the calling context must SR.
Look-ahead at Rend is = for context S LTRLLendRend but there is
11/23/2011 context S* C parallel to this one.
no 63
64. LR(1)
S L R
* L
L R R id
=
R FIRST(L)=FIRST(R)={*,id}
Shift-reduce conflict: id $
S [L,{=}] [L,{$}]
[R,{=}] [R,{$}]
* *
[L,{=}] [R,{$}] [R,{=}] id [R,{$}] id [L,{=}] [L,{$}]
=
[R,{$}]
11/23/2011 After procedure cloning 64
65. LALR(1) look-aheads
T0 T1 T2 T4
S’ .S$ S(.S) [$,)] S(S.) [$,)] S(S). [$,)]
S(S) S .(S) [$] S.(S) [)] )
S
S S. S. [)]
(
[$] S
T5 ( • After reduction S(S), parsing can
S’S.$ resume either in state T0 or T1.
• LR parser stack tells you which one to
resume from
• LALR(1) look-aheads in state T1 are
interesting. Item S(.S) gets look-ahead
from item S .(S) in state T0 as well as
item S(.S) from state T1.
11/23/2011 65
66. Parsing techniques
• Our focus: techniques that perform breadth-first
traversal of GFG
– similar to online simulation of NFA
– input is read left to right one symbol at a time
– extend current GFG paths if possible, using symbol
• Three dimensions:
– non-determinism: how many paths can I follow at a given
time?
– look-ahead: how many symbols of look-ahead are known
at each point?
– context: how much context do we keep?
• this is implemented by procedure cloning, independent of look-
ahead
11/23/2011 66
67. What we would like to show
• Obvious algorithm:
– follow all CFL-paths in GFG
– essentially a fancy transitive closure in GFG
– leads to Earley’s algorithm
– O(n3) complexity
• O(n) algorithms: LL/LR/LALR,…
– preprocessing to compute look-ahead sets
– maintain compressed paths
– ensure that Earley sets can be manipulated as a
stack
11/23/2011 67
68. What we would like to show
(contd.)
• SLL(k) = no cloning + decision at procedure start
• LL(k) = k-look-ahead-cloning+ decision at
procedure start
• LA(l)LL(k) = l-look-ahead-cloning + context-
independent k-look-ahead + decision at procedure
start
• SLR(k) = no cloning + decision at procedure end
• LR(k) = k-lookahead-cloning + decision at
procedure end
• LALR(k) = reachability-cloning + decision at
procedure end
11/23/2011 68
69. Computing context-independent look-ahead
• Intuition: S xNab | yNbc
– simple inter-procedural N a |
backward dataflow analysis in
GFG
– assume look-ahead at exit of S N
GFG is {$k}
– propagate look-ahead back {xa} {ya,yb}
through GFG to determine
look-aheads at other points x y
• How do we propagate look- a
aheads through non-terminal N N
calls? a b
– would like to avoid repeatedly
analyzing procedure for each b c
look-ahead set we want to
propagate through it
– need to handle recursive calls
– ideally, we would have a 2-symbol look-aheads
function that tells us how a
look-ahead set at the exit of a
procedure gets propagated to
its input
11/23/2011 69
70. Every LL(1) grammar is an SLL(1) grammar
START Let string generated by paths P and Q be SP and SQ
Cases:
C1 C2 -SP = a and SQ = a : grammar is neither LL(1) nor SLL(1)
-SP = a and SQ = b : grammar is LL1() and SLL(1)
x y
-SP = and SQ = : grammar is neither LL(1) nor SLL(1)
N -SP = a and SQ = :
- We show that there cannot be a context Ci for which the
generated string for the complementary context Ci’ is a
P Q - Otherwise, for context Ci, 1-lookahead for choice P is a
1-lookahead for choice Q is a
so the grammar is not LL(1).
- Therefore, there is no context Ci for which the 1-lookahead for
choice Q is a.
C1’ - But this means that the context-independent 1-lookahead
C2’ for choice Q cannot contain a.
- Therefore the grammar is SLL(1).
END
11/23/2011 70
71. LL(2) grammar that is not SLL(2)
START
-Consider the context-sensitive look-aheads at N.
-For context C1,
2-lookahead for choice P is {aa}
C1 C2
2-lookahead for choice Q is {ab}
x y -For context C2,
N 2-lookahead for choice P is {ab}
2-lookahead for choice Q is {bc}.
a -Therefore, grammar is LL(2).
P Q -Context-independent lookaheads:
2-lookahead for choice P is {aa,ab}
2-lookahead for choice Q is {ab,bc}.
-Since these two sets are not disjoint, the grammar is
not SLL(2).
a b -Grammar:
C2’ S xNab
C1’
S yNbc
b c Na
N
END
11/23/2011 71
72. Cloning for LR(k)
• From Sippu & Soissalon
– replace each non-terminal A in the original grammar
G with the set of all pairs of the form ([ ]k,A) where is
a viable prefix of the $-augmented grammar G
• [page 16] String 1 is LR(k) equivalent to string 2
if VALIDk( 1) = VALIDk( 2); i.e. exactly those items
valid for 2 are valid 1 and vice versa.
• An item [A . ,y] is LR(k)-valid for if
S rm* Az rm z = z and k:z = y
• Question:
– is this a finer equivalence class than LL(k)?
11/23/2011 72
73. Sanity condition on
equivalence classes
• If C1 and C2 are two START
contexts for some node N
and
– C1 = B1 + P
– C2 = B2 + P B1 B2
– B1 and B2 are in the same
equivalence class
C1 and C2 must be in the
same equivalence class
• Can we come up with a P
general construction
procedure for cloning, N
given a specification of
the equivalence classes?
11/23/2011 73