Assignment Type : Ai using prolog language

• AI Search Techniques

o The search algorithms can solve this problem easily so you must implement one of the uninformed search techniques and one of the informed search techniques to solve the problems


I. Problem #1

1. Problem#1 Overview
Given a list of positive integer Items whose elements are guaranteed to be in sorted ascending order, and a positive integer Goal, and Output is a list of three elements [A,B,C] taken from items that together add up to goal. The Output must occur inside the items list in that order (ascending order).

?-threeSum([3,8,9,10,12,14],27,Output).
Output=[8,9,10];
Output=[3,10,14].

?-threeSum([2,4,8,10,12,14],25,Output).
false.

?-threeSum([2,4,8,12,14,16],20,Output).
Output=[2,4,14].

?-threeSum([1,2,3,4,5,6,7,8,9],12,Output).
Output=[1,2,9];
Output=[1,3,8];
Output=[1,4,7];
Output=[1,5,6];
Output=[2,3,7];
Output=[2,4,6];
Output=[3,4,5].
2. Problem#1 Components:
This program consists of the following engines:

• Planner Engine: is responsible for:
• Taking the query in prolog entered by the user.
• Apply the planning algorithm using depth first search or greedy algorithm to get the path. This algorithm should be implemented in prolog.
• You must solve this problem twice (depth first search and greedy algorithm)



II. Problem #2

1. Problem#2 Overview
Daisy loves playing games with words. Recently, she has been playing the following Deletive Editing word game with Daniel.
Daisy picks a word, for example, "DETERMINED". On each game turn, Daniel calls out a letter, for example, 'E', and Daisy removes the first occurrence of this letter from the word, getting "DTERMINED". On the next turn, Daniel calls out a letter again, for example, 'D', and Daisy removes its first occurrence, getting "TERMINED". They continue with 'I', getting "TERMNED", with 'N', getting "TERMED", and with 'D', getting "TERME". Now, if Daniel calls out the letter 'E', Daisy gets "TRME", but there is no way she can get the word "TERM" if they start playing with the word "DETERMINED".
Daisy is curious if she can get the final word of her choice, starting from the given initial word, by playing this game for zero or more turns. Your task it help her to figure this out.

% deletiveEditing(Initial,End).
Each word consists of at least one and at most 30 uppercase English letters; Initial is the Daisy's initial word for the game; End is the final word that Daisy would like to get at the end of the game.

?- deletiveEditing(['D','E','T','E','R','M','I','N','E','D'], ['T','R','M','E']).
True.

?- deletiveEditing(['D','E','T','E','R','M','I','N','E','D'], ['T','E','R','M']).
False.

?- deletiveEditing(['D','E','I','N','S','T','I','T','U','T','I','O','N','A','L','I','Z','A','T','I','O','N'], ['D','O','N','A','T','I','O','N']).
True.

?- deletiveEditing(['C','O','N','T','E','S','T'], ['C','O','D','E']).
False.

?- deletiveEditing(['S','O','L','U','T','I','O','N'], ['S','O','L','U','T','I','O','N']).
True.

2. Problem#2 Components:
This program consists of the following engines:

• Planner Engine: is responsible for:
• Taking the query in prolog entered by the user.
• Apply the planning algorithm using informed search algorithm (greedy algorithm) to get the path.
This algorithm should be implemented in prolog.

Answers

Answer 1

Answer:

Explanation:

Assignment Type : Ai using prolog language

• AI Search Techniques

o The search algorithms can solve this problem easily so you must implement one of the uninformed search techniques and one of the informed search techniques to solve the problems

I. Problem #1

1. Problem#1 Overview

Given a list of positive integer Items whose elements are guaranteed to be in sorted ascending order, and a positive integer Goal, and Output is a list of three elements [A,B,C] taken from items that together add up to goal. The Output must occur inside the items list in that order (ascending order).

?-threeSum([3,8,9,10,12,14],27,Output).

Output=[8,9,10];

Output=[3,10,14].

?-threeSum([2,4,8,10,12,14],25,Output).

false.

?-threeSum([2,4,8,12,14,16],20,Output).

Output=[2,4,14].

?-threeSum([1,2,3,4,5,6,7,8,9],12,Output).

Output=[1,2,9];

Output=[1,3,8];

Output=[1,4,7];

Output=[1,5,6];

Output=[2,3,7];

Output=[2,4,6];

Output=[3,4,5].

2. Problem#1 Components:

This program consists of the following engines:

• Planner Engine: is responsible for:

• Taking the query in prolog entered by the user.

• Apply the planning algorithm using depth first search or greedy algorithm to get the path. This algorithm should be implemented in prolog.

• You must solve this problem twice (depth first search and greedy algorithm)

II. Problem #2

1. Problem#2 Overview

Daisy loves playing games with words. Recently, she has been playing the following Deletive Editing word game with Daniel.

Daisy picks a word, for example, "DETERMINED". On each game turn, Daniel calls out a letter, for example, 'E', and Daisy removes the first occurrence of this letter from the word, getting "DTERMINED". On the next turn, Daniel calls out a letter again, for example, 'D', and Daisy removes its first occurrence, getting "TERMINED". They continue with 'I', getting "TERMNED", with 'N', getting "TERMED", and with 'D', getting "TERME". Now, if Daniel calls out the letter 'E', Daisy gets "TRME", but there is no way she can get the word "TERM" if they start playing with the word "DETERMINED".

Daisy is curious if she can get the final word of her choice, starting from the given initial word, by playing this game for zero or more turns. Your task it help her to figure this out.

% deletiveEditing(Initial,End).

Each word consists of at least one and at most 30 uppercase English letters; Initial is the Daisy's initial word for the game; End is the final word that Daisy would like to get at the end of the game.

?- deletiveEditing(['D','E','T','E','R','M','I','N','E','D'], ['T','R','M','E']).

True.

?- deletiveEditing(['D','E','T','E','R','M','I','N','E','D'], ['T','E','R','M']).

False.

?- deletiveEditing(['D','E','I','N','S','T','I','T','U','T','I','O','N','A','L','I','Z','A','T','I','O','N'], ['D','O','N','A','T','I','O','N']).

True.

?- deletiveEditing(['C','O','N','T','E','S','T'], ['C','O','D','E']).

False.

?- deletiveEditing(['S','O','L','U','T','I','O','N'], ['S','O','L','U','T','I','O','N']).

True.

2. Problem#2 Components:

This program consists of the following engines:

• Planner Engine: is responsible for:

• Taking the query in prolog entered by the user.

• Apply the planning algorithm using informed search algorithm (greedy algorithm) to get the path.

This algorithm should be implem


Related Questions

Which is an example of a foley effect?

Answers

Answer:

Foley artists reproduce everyday sounds like footsteps, doors opening and closing, wind blowing, glass breaking, and other ambient noise.

Question # 9
Fill in the Blank
Complete the statement using the correct term.
The aerospace industry uses______________ simulators to train astronauts and design spacecraft.

Answers

Answer:

flight stimulators are used to train astronaut and design simple air craft

The groups within a tab are collectively
known as?

Answers

Answer:

the ribbon

Explanation:

Commands are organized in logical groups, which are collected together under tabs. Each tab relates to a type of activity, such as formatting or laying out a page. To reduce clutter, some tabs are shown only when needed.

The name for the instructions you write to a computer in a program

Answers

Answer:

Code

Explanation:

The code is instructions that you can write yourself or download from online

Answer:

Code

Explanation:

Code

The name for the instructions you write to a computer in a program

What will be the output of the following code snippet?

Answers

Answer:

D

Explanation:

Its gonna be of the class integer.

can i get help with computer language​

Answers

Answer:

yes

Explanation:

because you can choose you own language

I need help including my other one I posted

Answers

Answer:

2. I like the form of it, I like the porportion of it.

3. I dont know what a purpose of this maybe it a person wearing a tuexdo stepping out of his house or something.

4. Another thing that would work well is texture.

A license agreement specifies the number of
devices on which you can install the product, any
dates of expiration, and other restrictions. True or false?

Answers

The statement that a license agreement specifies the number of devices on which you can install the product, any dates of expiration, and other restrictions is true.

What is a license agreement?

A license agreement is a formal agreement that is given to a person to do or use something.

It is a legal contract between people or government and a person to authorize over any product.

Thus, the given statement is true.

Learn more about license agreement

https://brainly.com/question/14681311

#SPJ1

What is the purpose of Executive Order 13526?

Answers

prescribing a uniform system for classifying, safeguarding, and declassifying national security information, including information relating to defense against transnational terrorism.

when does computer store data permanently?​

Answers

when the device is unpowered.

The Texas Department of Education has offices throughout the state covering more than 268,000 square miles. State documents are stored on a large server in a central location, so that employees can access the data they need regardless of their physical location. The type of network used by the organization is most likely a _____.


LAN


WAN


MAN

Answers

Answer: WAN

Explanation:

You are approached by the representative of a company which sells equipment that
your company makes use of. During your conversation, the company representative
offers to provide one unit of the equipment for your individual home usage for free (i.e.,
as a gift) should you purchase 1000 units for company usage. What should you do?

Answers

Answer: Don't purchase.

Explanation:

I think that is the right thing to do. Don't get swayed by bribes or gifts because that is what a person with integrity does. Of course, if you ask your company if they're willing to buy, then buy it.

_______Is the process of organizing data to reduce redundancy
O A. Specifying relationships
O B. Duplication
O C. Primary keying
O D. Normalization

Answers

Answer:

the answer is D

Explanation:

Normalization is the process of reorganizing data in a database so that it meets two basic requirements:

There is no redundancy of data, all data is stored in only one place.

Data dependencies are logical,all related data items are stored

DUE IN AN HOUR PLS HELP
Random answers for points will be reported


Which one of these is an example of an output device digital pen headset keyboard mouse

Answers

Answer:headset

Explanation:because sound comes out of them

Answer:

Headset

Explanation:

It would be a headset because headsets "output sounds"

Digital pens, keyboards, and mice don't output anything.

Allan is a candidate for the position of Mayor in his town. He is worried about using email for the fear that it may be intercepted by the government and used by his opponent. What law protects his email from being intercepted by the government?
The
and its proposed update strengthen the online privacy of users by increasing requirements for governmental access to the stored data.

Answer: Electronic Communications Privacy Act

Answers

Answer:

This is correct.

Explanation:

I took the test and got it right.

Question 2 of 25
How could a video's file size be reduced so that it will take up less space on a
computer's hard drive?
A. By shooting it at a lower resolution
B. By shooting it at a higher resolution
C. By shooting it at a higher frame rate
D. By sampling the sound at the maximum rate

Answers

A, as a lower resolution will store less data per frame, reducing file size.

Choose the correct term to complete the sentence.

For most operating systems, the _______ function returns the number of seconds after January 1, 1970, 0:00 UTC.


O localtime()

O time()

O epoch()

Answers

Answer:

time() or time.time()

Explanation:

The time() method from the time module gives the amount of seconds after epoch, or Jan 1, 1970. Running this in the Python shell would return a number like this:

>>> time.time()

1652747529.0429285

For most operating systems, the time() function returns the number of seconds after January 1, 1970, 0:00 UTC. Thus, the correct option is B,

What is the time() function?

In python, the time() function is the function which returns the number of seconds that have been passed since an epoch. It is the point where time actually begins. For the Unix system, the time such as January 1, 1970, 00:00:00 at UTC is an epoch.

The time() method from the time module is used widely to give the amount of seconds which have been passed after the time period of an  epoch, or Jan 1, 1970. Running this in the Python shell would return a number like the one listed in the question.

Therefore, the correct option is B.

Learn more about time() function here:

https://brainly.com/question/12174888

#SPJ2

Do anyone know how to code like I need someone do a code for me?

Answers

Answer:

yeah i can depends on what exactly it is but probably

what are the four main components of programming languages and why is each one needed?

Answers

Answer:

input, output, arithmetic and conditional and looping

Which of the following types of promotion includes a two-way conversation?

Answers

It would be C. Personal selling. Hope it helps!
where are the answer choices?


Which type of device would be used on a laptop to verify
the identity of a user

Answers

Answer:

A biometric identification device

Explanation:

As biometric identification devices, laptops commonly use a fingerprint scanner or, for facial recognition, a camera.

Company ABC would like to select the topology that has the most reliability for data reaching its destination. Which topology should they choose?
bus
full mesh
partial mesh
ring

Answers

Full mesh because it is the answer and I been reading up in it

Characteristics of VR headsets​

Answers

Answer Believable Virtual Word. The believable virtual world is a key characteristic of Virtual Reality. ...
Immersive. ...
Feedback. ...
Interactive. ...
Virtual Reality Headset. ...
Computing Device (Commuter / Smart Phone) ...
Virtual Reality Input and Output Devices. ...
Fully Immersive Virtual Reality.

In this area, you want to focus on which hardware, application, personnel, or department(s) will be impacted by the security policy. For instance, what type of personal devices are allowed on the network and when? Must the personnel receive formal approval before using such devices on the network? What kind of activity is allowed on a personal device? Who is responsible for granting the permission to use a device on the network?

Answers

The type of personal devices that are allowed on the network are:

LaptopsSmartphones tablets

What devices do BYOD have?

BYOD is known to be Personal devices such as smartphones that organizations often gives permission for employees that are working from home so as to be able to have a flexible schedule and others.

Therefore, The type of personal devices that are allowed on the network are:

LaptopsSmartphones tablets

Learn more about personal device from

https://brainly.com/question/4457705

#SPJ1

Which method can be used for making a robot perform a different set of functions?

a. changing a robot's sensors
b. dismantling a robot
c. creating a new robot
d. rewriting software

Answers

Answer:

D. Because rewriting it can make it preform new functions.

Explanation:

What will be printed to the screen when the following program is run?

Answers

Answer:

The answer is 20

Explanation:

Hope this helps!

Answer:

40

Explanation:

Indexes for arrays in Python start at 0, which means the first item of an array is at index 0, the second item is at index 1, the third item is at index 2, and the fourth item is at index 3.

Therefore when my_list[3] is put inside the print function, the fourth item, 40, is printed to the screen.

Hope this helps!

Gigantic Life Insurance has 4,000 users spread over five locations in North America. They have hired you as a consultant to provide a
solution for standardizing Windows 10 configuration. There is a mix of desktop computers and tablets running Windows 10. The computer
and tablets come from a variety of vendors because Gigantic Life Insurance allows agents to purchase their own computers. How do you
recommend they standardize their Windows 10 installations?

Answers

First of all, when buying a set of Windows 10 operating system, It needs to buy Windows Server 2016 version as well in order to centrally connected to the Windows server machine. So coming to the edition of the Windows 10 version, we need to buy Windows 10 Enterprise edition for your infrastructure. So, the configuration can be like for each computer machine you must use 8 GB of memory and 500 GB of storage. For tablet, it can choose 4 GB memory and 32 GB ROM. Windows tablet comes with already installed OS. But for installation of Windows enterprise client OS, it needs to choose network mode of installation.

What is windows?

A window is a separate viewing area on a computer display screen in a system that allows multiple viewing areas as part of a graphical user interface (GUI). Windows are managed by a windows' manager as part of a windowing system. A window can usually be resized by the user.

Learn more about window's here,

https://brainly.com/question/26388929

#SPJ1

ANSWER QUICKLY!!!

Which aspect of planning is a preventive action?

Answers

A preventive action aims to correct a potential problem. Unlike a corrective action, which fixes the root cause of a current issue, preventive actions try to address problems before they happen

How to powerwash chromebook

Answers

Answer:

you only need to select restart after you sign out of your account also I would make sure everything you need is backed up because otherwise everything you have will get deleted I accidentally had that happen to me last week or the week before, I didn’t realize it was going to need to be reset so I didn’t save the majority of my answers. So now I have barely anything done and I’m behind.

Explanation:

I hope it helps you though.

what is the input for air cooler computer science​

Answers

Answer:

cooling

Explanation:

Air cooling is a process of lowering air temperature by dissipating heat. It provides increased air flow and reduced temperatures with the use of cooling fins, fans or finned coils that move the heat out of a casing such as a computer …

Other Questions
Energy stored in foods is _____________; digested food releases ___________ energy for movement and ________________ energy as heat. Select one or more of the following groups that experienced hardships in the West: Immigrants, African-Americans, Native Americans, Women, Vaqueros or Mormons. Write an essay to explain some of the hardships that these groups might have faced in the west. Please help asap What is being done to solve water scarcity in Africa? I'm in 7th grade and am doing high school math! Help! difference between Johannesburg and durban? An enzyme controlled reaction was carries out at 36C. After 3 minutes, 240 cm' of product had beenproduced. Calculate the rate of reaction is cm/s Question 5 (2 points)Jason puts his money in an investment option that has high risk, but also thepotential for a large return. He gets a dividend check every January from thisinvestment. Jason most likely invested in a(n) ... (CS2) The intelligence-sharing arrangement between the u. S. , u. K. , canada, australia and new zealand is known by what name?. NEED HELP ASAP WILL GIVE 20 POINTSFloods are natural disasters that can cause what other natural disaster?tsunamilandslidehurricaneerosion n/8=11/5 what does n equal Identify the products of this single-replacement reaction between sulfuric acid and aluminum. Then balance the equation___H2SO4 + ___Al ___ + ___ Select the correct answer from each drop-down menu.Three students used factoring to solve a quadratic equation.x+17x+72=12.Jordan's Solution x + 17x + 72 = 12, (x + 8)(x + 9)= 12, x+8=12 & x+9=12Keith's Solution x + 17x + 72 =12, x + 17x +60 =0, (x +5)(x +12) =0 x + 5 = 0 & x + 12 =0.Randall's Solution x +17x +72 = 12,x2 +17x = -60,x(x +17) = -60, -60 & x +17 = -60.he equation was solved correctly by ____. The solutions of the equation are____. A Farmer Leans a 12 ft Ladder Against A Barn. The Base of the Ladder Is 6ft From The Barn.l To The Nearest Foot, How High on the Barn Does The Ladder Reach??? when working with track changes, what is the difference between simple markup and all markup? 6) What will be the new position of the givenpoint (0, 6) after translation of 6 units downand 3 units right?a) (6, 3)b) (3, 0)c) (-6, 3)d) (-3,0)Please help omg Question 12 of 21Series J 30-48.- MANUFACTURING PRODUCTION-INDEXES BY GROUPS(FEDERAL RESERVE BOARD): 1919 TO 1945DURABLE MANUFACTURESTOTAL,YEAR MANUFACTURES Total,Iron and MachinerysteelTransportation Lumber andequipment productsdurable3031323334361945214274183343487109194425235320643971912519432583602084487351291942212279199340464134194116820118622124513419401261391471361451161939109109114104103106193887786882729019371131221231261231131936104108114105110105Which conclusion about the American economy can best be drawn from thischart?OA. Spending by households slowed as a result of war scarcity.B. Consumer goods were made of natural resources from newtrading partners.C. Most American products were bought by the government insteadof by private citizens and corporations.D. Manufacturing increased quickly in response to war productionneeds. can someone help me pls Your first draft can also be your final draft. TrueFalse A motor car shaft consists of a steel tube 30 mm internal diameter and 4 mm thick. The engine develops 10 kW at 2000 r.p.m. Find the maximum shear stress in the tube when the power is transmitted through a 4: 1 gearing. What is the equation?