top of page

Java Project

Public·2 members

Binary Search In Java

Binary search is used to search an key element from array of elements. Binary search is faster than linear search. It can be used when the elements are in a sorted sequence and all the key elements are unique. It takes O(logn) time where as the linear search takes O(n) time in worst case.


Algorithm:

  • Compare the middle element with key

  • If the middle element matches with the key, then return index of middle element

  • Else if middle elements is greater than key, then key can only be lie on half sub array before the mid so we recursively find the key in half sub array

  • Else key can be found in half sub array after the mid


36 Views

Solution, JavaFX GUI: Creating shape(circle, ractangle, etc) to fill color

JavaFX GUI


Output formate



About the project

Design tow button in GUI, clicking these buttons will create different shapes (square, rectangle, circle, ellipse, etc). The name of the button will be the name of the shape.

For example square button, circle button


164 Views

Solution, Creating Furniture app usig JavaFX

About the project

GUI:

GUI contains buttons:

  • Add Chair,

  • Add Table,

  • Add Desk,


62 Views

Solution, JavaFx GUI

About the Project

GUI:

GUI contains buttons:

Register, Login, Cancel


66 Views
    bottom of page