strings, C/C++ Programming

A string S is said to be "Super ASCII", if it contains the character frequency equal to their ascii values. String will contain only lower case alphabets (''a''-''z'') and the ascii values will starts from 1 (i.e ascii value of ''a'' is 1 and ''z'' is 26). Now given a string S, you can perform operations, namely, add, delete and replace of any character present in the string. Every operation will consists of following costs

add = 2 unit
replace = 1 unit
delete = 3 unit

Your task is to convert the string to super ascii with the minimum cost. While converting the string to super ascii, the final string should contain the same characters as in the input string.
Posted Date: 7/19/2016 4:59:44 AM | Location : USA







Related Discussions:- strings, Assignment Help, Ask Question on strings, Get Answer, Expert's Help, strings Discussions

Write discussion on strings
Your posts are moderated
Related Questions
program that generate university statistical bar graph using 3d function

I need to create a connection to FIFA Ultimate Team 14, I want to utilize C++ specifically for the reason that that is the language I have the most experience in. There are a co

Program to define an array in c: Write a program to define an array and print the value of array. void main() { int a[10]={0,11,21,34,44,75,46,57,88,89},i,j,k; clr

Program to check even and odd numbers: int main() {                 int  your_number;                 cout                 cin >> your_number;

Scrape a site and save as csv Project Description: I want a programmer to create scraping software. I'll want every page scraped of name, job title, company, and url. There a

C program to demonstrate Pointer to string: void main() {                 int a;                 char str[]="hello how are you?",*ptr_str;                 ptr_str=&

How to use HTTP Headers inside PHP? Write the statement through which it can be added? HTTP headers can be used in PHP by redirection that is written as: Headers can be

how objects are initialized dynamically?

Ask question #Minimum 100 words acceptedEducational Objectives: After completing this assignment, the student should be able to accomplish the following: Apply generic algorithms i

This is what I need help with. "Create a program creates an interface allowing the user to select from some other programs I have made one being a money converter and the other ca