0% found this document useful (0 votes)
10 views4 pages

Technical Questions

The document outlines a series of programming tasks to be implemented in Dart, including counting negative elements in an array, reversing a string, calculating the sum of digits in a number, finding the second largest unique number, removing duplicates from a list, identifying a missing number in a sequence, and determining the longest substring without repeating characters. Additionally, it includes problems related to subset sums, string expansion based on character counts, generating unique permutations, and a Flutter UI design task based on a provided Figma link. Each task is accompanied by specific input and output examples to guide implementation.

Uploaded by

nmschool226
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views4 pages

Technical Questions

The document outlines a series of programming tasks to be implemented in Dart, including counting negative elements in an array, reversing a string, calculating the sum of digits in a number, finding the second largest unique number, removing duplicates from a list, identifying a missing number in a sequence, and determining the longest substring without repeating characters. Additionally, it includes problems related to subset sums, string expansion based on character counts, generating unique permutations, and a Flutter UI design task based on a provided Figma link. Each task is accompanied by specific input and output examples to guide implementation.

Uploaded by

nmschool226
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

Problem Solving:

Things to note / Instruction:

* You are expected to approach all Questions in Dart Programming Language.

Program:

A) Write a program to count total number of negative elements in an array.


arr= [7,18,45, -6,19, -1,0]

B) Write a program to display string from backward without using built in


method. str=” flesruoYevileB”

C) Write a function to calculate the sum of all digits in a given number.


num= 641108
D) Write a function that finds the second largest unique number in a list of
integers and returns the sum of the largest and second largest unique
numbers.
Input: [10,9,3,4,5,6,7,13]
E) Write a function that takes a list and returns a new list with all duplicate
elements removed.
Example: Remove Duplicates ([1, 2, 2, 3, 4, 4, 5]) should return [1, 2, 3, 4, 5]
F) Given a list of integers from 1 to N, with one number missing, find the
missing number.
Example: findMissingNumber([1, 2, 4, 5]) should return 3
G) Longest Substring Without Repeating Characters
Problem Statement:
Given a string `s`, find the length of the longest substring without repeating
characters.
Input:
- A string `s` consisting of ASCII characters
Output:
- An integer representing the length of the longest substring without
repeating characters.

Example:
Input: s = "abcabcbb"
Output: 3
Explanation: The longest substring without repeating characters is "abc",
which has a length of 3.

H) Array Problem:
Given an array arr[] of non-negative integers and a value sum, the task is to
check if there is a subset of the given array whose sum is equal to the given
sum.
Examples:
Input: arr[] = {3, 34, 4, 12, 5, 2}, sum = 9
Output: True
Explanation: There is a subset (4, 5) with sum 9.
Input: arr[] = {3, 34, 4, 12, 5, 2}, sum = 30
Output: False
Explanation: There is no subset that add up to 30.

I) String Problem:
Write a program to give the following output for the given input
Eg 1: Input: a1b10 Output: abbbbbbbbbb
Eg: 2: Input: b3c6d15
Output: bbbccccccddddddddddddddd
The number varies from 1 to 99.

J) Permutation Problem:
Given a collection of numbers, nums, that might contain duplicates, return all
possible unique permutations in any order.
Example 1:
Input: nums = [1,1,2]
Output:
[[1,1,2],
[1,2,1],
[2,1,1]]
Example 2:
Input: nums = [1,2,3]
Output: [[1,2,3],[1,3,2],[2,1,3],[2,3,1],[3,1,2],[3,2,1]]

Flutter Ui Design Task:


Create a Flutter application that implements the user interface design as
provided in the Figma link below.
Design Figma Link:
https://www.figma.com/design/n5oWukWkoDiUFDZvmct14O/Codia-AI-Design%3A-Screenshot-to-
Editable-Figma-Design-(Community)?node-id=0-1&p=f&t=QfBjpjaoeGPrf3jX-0

You might also like